All perfect praise be to Allah, The Lord of the Worlds. I testify that there is none worthy of worship except Allah, and that Muhammad, sallallaahu`alayhi wa sallam, is His slave and Messenger.
The first thing that was sent down from the Quran was the beginning of Surah Al-Alaq, not Al-Fatihah, and at the beginning when Gabriel, peace be upon him, came down to the Prophet, sallallahu ‘alayhi wa sallam, in the cave, he did not know who he was, and the Prophet, sallallahu ‘alayhi wa sallam, was terrified by him. Then he, in panic, went back to Khadijah, may Allah be pleased with her, and she took him to her cousin Waraqah ibn Nawfal, who assured him that he was the Angel Gabriel, peace be upon him, who had sent down the revelation to Moses. Then the revelation paused for a while. Later, the revelation resumed as mentioned in the Hadith of Jabir ibn Abdullah who said that he heard the Prophet, sallallahu ‘alayhi wa sallam, saying: “While I was walking, I heard a voice from the sky. I looked up towards the sky, and behold! I saw the same Angel who came to me in the Cave of Hira', sitting on a chair between the sky and the earth. I was so terrified by him that I fell down to the ground. Then I went to my wife and said, 'Wrap me in garments! Wrap me in garments!' They wrapped me, and then Allah revealed: {O you, (Muhammad) wrapped-up (in garments)! Arise and warn} until His saying {and desert the idols}. After that, the Divine revelation came more frequently and regularly.” [Al-Bukhari and Muslim].
And when the Divine revelation started coming more frequently, He, sallallahu ‘alayhi wa sallam, knew that he was Gabriel, peace be upon him, and Allah the Almighty told him in the Quran that He sent him down with the revelation to him, as He the Almighty says (what means): {Whoever is an enemy to Gabriel – it is [none but] he who has brought it [i.e., the Quran] down upon your heart, [O Muhammad], by permission of Allah confirming that which was before it and as guidance and good tidings for the believers} [Quran 2:97]. Allah the Almighty guaranteed the guidance of the Prophet, sallallahu ‘alayhi wa sallam, as He the Almighty says (what means): {And He found you lost and guided [you]} [Quran 93:7] Al-Qurtobi noted in his explanation: it means “you were unaware of what was planned for you about the Prophecy affairs, therefore He guided you.”
Allah knows best.