I thought this was only happening to me but when you enter water or lava, your player can't fly anymore. Now I thought this may be part of MC itself but I went on a singleplayer world and tested it, it's not. Something is stopping you from flying when you're in water.
To reproduce:
- Simply walk into water or lava and try to fly out