Ultimately I think that's a big problem for a lot of classes, their class identity, and thus, niche, is hard to pin down. A Fighter is a guy who fights with weapons and armor, which is something several classes can do. A Wizard is a guy who casts spells, something that isn't very unique either- the only unique thing there is the Wizard needs to have a spellbook to function, while everyone else gets spells in a different way.
The Barbarian, as presented in the original Unearthed Arcana, was a better Ranger than the Ranger when it came to their survival and outdoors skills in many respects- they couldn't skulk about, so they might not be as proficient as hunters, but they had a host of abilities Rangers lack. The Rage mechanic they're built around now didn't even exist in AD&D- their Ranger-like abilities were stripped out to give them something that would set them apart from other classes.
Animal Companions? Originally a Druid thing, taken from them because WotC made Wild Shape so much more important to the class than their overall attunement to nature- gone is any bonuses to save against fire or lightning, the ability to identify plants or animals, resistance to fey magic, or even the ability to move in natural terrain unimpeded.
Going back to the Fighter, we can see the problem. If the core class fantasy of the Fighter is literally "guy who fights with weapons and armor" and we back that up with "guy who makes the most attacks per round" (with small nods to survivability in the form of Second Wind* and Indomitable), when one of the foundational principles of 5e is "everybody fights" and "no class is necessary to play the game", the Fighter isn't better at fighting than anyone else until very high levels!
At levels 1-10, several classes fight just as well as the Fighter and possibly better in certain circumstances. But these other classes might be able to do more when not fighting, which seems a bit strange, doesn't it?
It's not that the Fighter isn't a playable class. It's perfectly serviceable, and it does eventually pull ahead of it's peers, but usually only past the levels that are normally played. So for half the game, it can be hard to see what makes the Fighter exceptional, and it's not like most other classes stop being very good past level 10 anyways (The possible exception I'd make here is the Barbarian- I've never seen a level 11+ Barbarian in play, so maybe it's better than it looks on paper, but it seems to really fall behind compared to it's peers to me).
Compare and contrast the Fighter and the Paladin- the Paladin very likely has the best defensive package in the whole game, and not only is it very durable, it has abilities that can benefit it's allies as well. While not having 3 and eventually 4 attacks does make the class fall behind over the course of a day, Smite gives the class very good burst damage that makes up for some of this. In fact, the Paladin gets enough of the Fighter's kit (Fighting Style, hit dice, armor, weapons) on top of it's own special abilities (Lay on Hands, spellcasting, smite, aura of protection, etc.) that I'm always surprised that these conversations always end up revolving around Fighter vs. Wizard- even a half caster like the Paladin seems flat-out busted compared to the Fighter, yet all I ever hear is "Paladin is a strong class" (outside of some people who desperately want Paladins to be able to lose their powers at the drop of a hat again, lol).
Fighter vs. Wizard is really apples and oranges for the most part- the pitfall of the "Fighter the Mathening" thread is trying to compare the damage outputs of the two classes to prove a point of superiority. Which the Fighter generally wins- there are certainly circumstances where a Wizard can deliver insane damage, but it cost them far more precious resources to do this than the Fighter does. However, the Wizard can use their resources to do other things- and while that might not come up in most games, when it does, it can easily get out of hand.
The Fighter lacking much in the way of resources to do things other than fight is quite interesting to me in that it reinforces the Fighter's niche (they're the guy who fights, remember), but in a negative way- they can struggle to do anything more than other classes can accomplish, because that's not their thing, and yet, what they gain from this narrow focus doesn't really seem on par with what they lose to some.
Despite this narrow focus, the Fighter certainly could do more in combat, but the base class is constrained by the developers not wanting the Fighter to become the combat class. Thus it remains as a combat class, and is held back from being more until the back 10 of the course.
So the Fighter needs it's subclasses to do more to pull the class ahead. Whether or not it accomplishes this is a subject of lengthy debate- I can't say much here since I've only seen Battlemasters and Champions played. In my mind, the Battlemaster is superior to the Champion, but even then, by level 7, I no longer felt like I had much to look forward to.
Which is probably the reason these debates never seem to end. Some people are perfectly happy with what the Fighter gives them. You could point to "well class X gets Y", but they don't care because they didn't want Y in the first place!; if they did, they'd not be playing Fighters. Other people don't really get why Fighter doesn't get more when class X gets Y, not seeing the balance point.
I'm in that latter camp myself, where I think the Fighter is too narrow, and doesn't get enough. But I think what we all have to accept is, there are those who don't want more complexity or depth to the venerable Fighting-Man class. Or who fear that it will become something unrecognizable, or even impossible to use in the games that they enjoy if it was given more and better toys. Maybe we should cede that ground; after all, we do have those other classes to play.