Medieval battles involved many more people, and the leaders were on horseback usually. They could pick and choose where to have their cavalry charge to sway the battle, and not just charge into a hopeless melee.
Also, they were surrounded and accompanied at all times by elite troops meant to protect them. If the leader was wounded, the bodyguard/retainers would surround him and help him escape.
Also, the goal was not to kill everyone on the enemy side, but to cause panic and route them, making them flee. So lots of people survived...but the leaders were usually mounted (could flee much easier). They also had the best arms, armor, and training.
That being said, many royalties did die. It was much more important (profitable) to try and capture them alive though, and this happened more often.