It seems you have cerumen. Water entry causes the cerumen to swell and block your ears
Next Steps
Consult a good ENT surgeon and get your ears cleaned by suction or syringing.
Health Tips
Using ear buds will make the condition worse by causing pain and wax impaction.