The Prophet (ﷺ) prayed and stood up following the first two rak'ahs, and they said (SubhanAllah). He carried on, then when he finished his prayer he performed two prostrations, then he said the Salam.
Sunan an-Nasa'i Book 12, Hadith 150