But, why do all classes in a RPG be able to do everything as well as all the others?
They don't have to do everything as well as each other. Classes need niches (which means spells like Knock aren't awesome.) But a player should be able to have roughly the same amount of fun and effectiveness in combat with any class.
I second that! No class should be able to entitrely replace another. Which is exactly why some people tend to enjoy to play systems where a melee character can still be more than a caster`s meatshield at higher levels.
Take the rogue for example: He is stealthy, he can sneak up on pepole in combat and deal significant damage and finally, he is the only class in editions prior to 4E who can fid and disable traps.
At second level the wizard gets Invisibility and later on, he gets Improved Invsibilty. Add fly and you know why even somethig like tremorsense does not stop him from sneaking past.
He can deal significant damage but he has to spend time setting up for that while the wizards deals the same damage to multiple enemies and all the preparation that he needs to pull this off is Line Of Sight.
And finally, the only one who can disarm traps is the rogue so one might expect te rogue to really shine here. "Summon Monster X" is the answer to all your trapfinding problems. You do not have to disarm traps if you can set them off without any real opportunity cost.
Issues like this make people womder about class balance and issues like these explain why some people contemplate about such idealistic concepts as "balance".

(Dungeons & Dragons)
Rulebook featuring "high magic" options, including a host of new spells.