I pay my gym fees so the pool is available to me when I want to swim.
Its annoys me that they are using the lessons to get extra money at the expense of fee paying members. Would expect it at a municipal pool and I think you would be right. At a private gym/pool I expect it to be available to me.
I left a gym for this reason. When I joined, they didn’t mention kids’ swimming lessons at all. Then I found that every night after work the pool was unavailable from 4-6pm because of swimming lessons. My contract said “anytime access” and the gym was open 7am to 10pm. I wanted to swim after work, and I couldn’t. Even if I had wanted to say, swim at 6pm after the last lessons finished, the changing room was full of shrieking kids running around and pointing at other people’s “boobies” and “front bottoms” while you try and change. That’s why I didn’t join a municipal gym ffs.
My gym now does do lessons, but the very little ones have a kiddie pool, and they don’t close the whole pool off for the older ones’ lessons. There is adult only swimming time after 7pm and a families/kids session on a Saturday afternoon, which is made very clear to members that this session is only for children and their parents/carers.