Why are you supposed to repeat shmoneh esreh on certain days if you forgot to say the special insertion pertaining to that day? If, for example, you realize at the end of shmoneh esre during aseret yemei tshuva that you forgot to say hamelech hakadosh, why does that warrant a repetition of the entire shmoneh esre?
In general, as explained in Shulchan Aruch Horav Siman 114:8 if one changes the start and end of any Beracha from the way the Anshei Keneses Hagdolah established, then the Beracha is invalid hence the person did not fulfill his/her obligation. Now, the first 3 Berochos are considered one unit and the last 3 Berochos are considered one unit, therefore, if one made a mistake in one of them (meaning: 1 of the 3 first or 1 of the 3 last Berochos) then all 3 are invalid. However, the other 13 Berochos are separate units. In short, when one makes a mistake, and did not yet finish Shmone Esrei, s/he goes back to the beginning of that unit, i.e. if one forgets Tal Umatar they go back to the Borech Aleinu unit; if one forgets Hamelech Hakodosh they go back to the first 3 Berochos unit. But once s/he finished SA there is no way to go back to a unit without starting over from the beginning.
Besides the beginning and ending of Berochos there are certain phrases which the Anshei Keneses Hagdolah ordained that they must be said and if they were not said then that unit is invalid and one has to go back to that unit as explained above.
[Edit:] Besides the beginning and end of Berochos there are other factors as well like the lack of mentioning the uniqueness of the day which is said of the recognition of the day given to us by HKBH, like Rosh Chodesh, calls for a repeat. The lack of mentioning Gevuras Geshamem is as important as Techiyas Hameisim (but it can't be mentioned in the winter because at that time of the year it's a curse) and therefore the lack thereof calls for a repeat. Asking for rain in Bareich Aleinu is very important because we are asking HKBH to keep us alive by giving us food (rain causes food to grow), lack of asking for our livelihood straight from The Source of Life calls for a repeat.(In the winter we don't ask for rain because then it's a curse.) By Hamelech Hakodosh (and also Hamelech Hamishpot according to those who apply the same rules) it's because we must be aware and cognizant of the fact that HKBH is judging the world and lack of this recognition calls for a repeat.