you can count the bullets you shoot and load
But in real life, you're probably (rather painstakingly) loading magazines yourself, so you're more familiar with how many rounds are in each one. Most video games skip such mundanities, which makes things a lot less tedious, but it does mean you're not automatically familiar with the magazine capacity of the gun you're using, especially when switching to a different gun. So it can be helpful to have a reminder of magazine capacity, at least.
Or, if you've picked up a gun from a recently deceased enemy... In real life, if you had time, you'd pull the mag and check to see how many rounds it had left. But few if any games have a mechanic allowing you to do that. (Maybe some more realistic VR ones?) So in lieu of that, it's helpful to simply have a number on screen telling you that important information.