Read This Hadith To Understand :-
Narrated Al-Bara’ ibn Azib:
We went out with the Messenger of Allah (ﷺ) accompanying the bier of a man of the Ansar. When we reached his grave, it was not yet dug. So the Messenger of Allah (ﷺ) sat down and we also sat down around him as if birds were over our heads. He had in his hand a stick with which he was scratching the ground.
He then raised his head and said: Seek refuge with Allah from the punishment in the grave. He said it twice or thrice.
The version of Jabir adds here: He hears the beat of their sandals when they go back, and at that moment he is asked: O so and so! Who is your Lord, what is your religion, and who is your Prophet?
Hannad’s version says: Two angels will come to him, make him sit up and ask him: Who is your Lord?
He will reply: My Lord is Allah. They will ask him: What is your religion? He will reply: My religion is Islam. They will ask him: What is your opinion about the man who was sent on a mission among you? He will reply: He is the Messenger of Allah (ﷺ). They will ask: Who made you aware of this? He will reply: I read Allah’s Book, believed in it, and considered it true; which is verified by Allah’s words: “Allah’s Book, believed in it, and considered it true, which is verified by Allah’s words: “Allah establishes those who believe with the word that stands firm in this world and the next. -Quran 14:27“
The agreed version reads: Then a crier will call from Heaven: My servant has spoken the truth, so spread a bed for him from Paradise, clothe him from Paradise, and open a door for him into Paradise. So some of its air and perfume will come to him, and a space will be made for him as far as the eye can see.
–Sunan Abi Dawood, 4753 ; Grade: Sahih (Al-Albani)
May Allah Guide us all