Do not sit on the graves and do not pray facing towards them.

Sahih Muslim Book 11, Hadith 126