It wasnarrated that Anas bin Malik said:
"When the Prophet (ﷺ)died,there was a man in Al-Madinah who used to make a niche in thegraveand another who used to dig graves without a niche. They said:'Letus pray Istikharah to our Lord and call for them both, andwhicheverof them comes first, we will let him do it.' So they wereboth sentfor, and the one who used to make the niche-grave camefirst, so theymade a niche-grave for the Prophet (ﷺ)."
English reference: Vol. 1, Book 6, Hadith 1557
Arabic reference: Book 6, Hadith 1624