That isn't complicated, now is it? The flu vaccine doesn't offer 100% protection; it never has. But if people who take the shot do get sick, their illness will be less serious, and they won't end up in the hospital.
Same for the best of the COVID vaccines, except that they're considerably more effective than the flu vaccines.
The flu vaccines are, in some parts of the world, two-dose medications.