I just attended three classes of swimming, and I am unable to swim at the surface when I kick my legs. I can breathe inside the water. But for kicking the legs, I am in a slant position and unable to bring both legs to the surface and kick. 10-12 of my co-learners have learnt this, learning new techniques and moving ahead. I do not have fear of water, as I know. Standing on one leg, I bring the other leg up, but the second leg when pushed up, goes up a little and the first leg also comes down. I am also not able to keep my legs straight without bending. If this goes on, I may have to quit. The coach does not help except give instructions. Feeling very helpless and dejected.
First and most importantly, you must learn at your own pace. There is no standard number of lessons you will learn to swim in, and just because others in your class are able to kick their legs does not mean you should be able to as well.
I will presume from the information you have given that you are an adult beginner. If you are able to submerge your face and breathe out into the water then you have no fear of the water but I am wondering how relaxed you are in the water? The more relaxed you are then, the more your body will be encouraged to float.
My ebook The Complete Beginners Guide To Swimming contains a chapter on relaxing in the water plus all the other essential elements needed to stay afloat as you swim. Click here below for more details.
The leg kick you describe must be relaxed with a slight knee bend and a very loose ankle. This will allow your leg and foot to generate some propulsion and movement as well as remain near the water's surface. However, if your head or face is above the water's surface it will make keeping your legs up very difficult and even cause them to sink.
I wonder why your coach allows you to persist with this front crawl leg kick if you find it so difficult. Some people learn front crawl leg kick quickly and go on to learn the full stroke, whereas others find it difficult.
If you were a pupil of mine I would be teaching you breaststroke as this is a far easier swimming stroke for an adult beginner to learn. The leg kick is simultaneous instead of alternating, and it can be performed with the legs deeper in the water and still be effective. Maybe ask your coach to teach you breaststroke instead?
Whatever you do, remember we all learn at different speeds, and others must not put you off in your class. After all, you began taking lessons because YOU wanted to learn to swim, so be determined and follow your ambition. Good luck!