Because a lot of people don't want mundane classes that have superpowers that replicate the reality-bending ability that magic has. Otherwise that spellcaster isn't so special anymore. And the tradeoffs for being able to learn those abilities (fragility) then become an extra punishment if the fighter can do the same stuff.
If it has a ton of other mitigating factors (like concentration, having the spell prepp'd, or even having it learned in the first place, being limited in the number of times you can use it, etc, etc)? Then sure. It is supposed to do things that mundane skills can, but better. That's the whole point; to have choice as a player of what kind of character you want to play. Do you want to be pretty good and be able to do something reliably and every time? Or do you want to play someone who is guaranteed success, but is very limited in the frequency, maintainability, and reliability of it's usage?
For the life of me, I will never understand why people always seem to forget the buttload of mitigating factors around magic whenever they start slinging out the "magic is superior" argument.