The problem with the mask flooded by water is caused by the neo-natal glottis reflex.
This is the reflex that any human has at birth, and is triggered by the contact of water to some neural receptors located around our nostrils. When they detect water, the reflex automatically closes the epiglottis valve, impeding to breath (but also to drown).
It is called "neo-natal" reflex because you can easily detect it in very young babies, but this reflex usually disappears spontaneously after a few months, and most people do not have it at the age they start diving.
However, approximately 1 every 10 adults still has this reflex: so in a class it is quite common to have one or two subjects which are in serious trouble as soon as their mask is flooded: they cannot breath anymore, as the glottis is closed. They cannot exhale from the nose, for evacuating the mask. And after a few seconds impeded to breath, they swim to the surface, suffering a serous risk of lung over-expansion, as they cannot exhale during the ascent.
It is not "all in their brains", as this reflex does not affect the brains, but their automatic reflex system, which is mostly out of voluntary control.
With a lot of patience and training, these subjects can become capable of counter-effecting the glottis closure by voluntary control, reopening it after the reflex is triggered: there is no way to avoid the reflex, indeed, but staying calm, usually after 10-30 s of apnoea, and exerting strong voluntary control, the glottis opens again, and the subject can breath, and exhale through the nose, evacuating the mask.
These subjects are indeed exposed to troubles in their diving career, as any event causing the mask flooding or being removed will impede them to breath for a while.
Nowadays, with a patient instructor who understands the problem, these people can still be certified and can afford some moderate diving experiences. In the past, when I was working as an instructor, we were told that those subjects were not allowed to become divers, and they were simply expelled from the course, as physically not fit.
So, for people not suffering of the neonatal reflex, evacuating the mask looks like a trivial task. For people suffering of this problem, the mask evacuation is an almost unsurmountable problem.