Peace be upon you. According to Grand Ayatollah Khamenei and Grand Ayatollah Sistani, if one is required to perform the additional rakat of caution, they should immediately intend to perform it and say the takbir right after finishing the prayer (without engaging in anything that invalidates it). Then, they should recite Surah Al-Fatiha (without any other surah), perform the ruku (bowing), and prostrate twice. If their obligation is to perform one additional rakat, they should conclude with the tashahhud and tasleem after the two prostrations. However, if their obligation is to perform two additional rakats, they should stand up after the two prostrations and perform another rakat like the first one, then conclude with the tashahhud and tasleem. May you be successful in all good deeds.