Because the Prophet (ﷺ) said: "May Allah curse the Jews, for they took the graves of their prophets as places of worship." And the statement regarding the dislike of praying in graves. ‘Umar ibn Al-Khattab (may Allah be pleased with him) saw Anas