SOLVED: It turned out that the SATA cable was damaged. After replacing it with a new one, it worked again! PS.