I had a lesson myself a few weeks ago. It has been a long time since I had a lesson, and I really wanted to get the most out of it. I admit to playing while the teacher was talking, even though I tried very much not to - because I didn't want to seem rude. However, I wanted to play because I wanted to explore the teacher's suggestions and uncover more things, on that basis, that I could ask her about. In other words, I had to fight the urge to play - but I would have gained a lot more from the lesson if I had felt free and had consent to play even while she was talking.
I also think that it is a good sign that they want to play the piano, instead of avoiding playing. During my lesson, I wanted the teacher's explicit instruction so I could explore the piano more - it was more a practical thing, with a practical need, rather than an intellectual exercise. Maybe it is a good thing that kids want to explore the piano? Maybe they want to see what sounds they can produce, and the movement is for discovery?
Sometimes, though, it is kids just being kids - I don't like it when they swing their legs because I don't like it when the piano gets kicked.
I tend to think, though, that is a kid isn't paying attention while I am talking, if I have first got their attention, than maybe I am saying something they don't understand or they are not ready for in some way. (But my biggest problem as a teacher, I think, is not being the 'boss'. Perhaps I am not strict enough in some ways.)
I find that some of my students relax more and play better - as well as gaining more from the lesson, if the talking is independent of the playing - ie. sometimes they play while I am talking, and they talk while they are playing as well. But we also talk when they are not playing. (This is mostly the older ones - over 10 years. I have some around 7-8 who I use this 'play' as the springboard of creative work. I treat the playing as creative exploration - and it seems to work. They love learning how all these fiddling things can be turned into improvisation, and the students I have at this age are all writing their own pieces now. With the younger ones, I guess it's probably attention issues.)
It is important that we as teachers are comfortable and are in charge of the lesson. Perhaps they could have some quiet way of expressing their need to move? - something to fiddle with that is silent and not too interesting (distracting).
(Sorry if my post sounded too opinionated before. I wrote when I was over-tired, but wanted to give some food for thought. What I really wanted to say was not to feel too frustrated about it, but that the behaviour might sometimes even be a really good sign. However, I have recently acquired two students who aren't into the lessons as much as my other students - and I can relate to the frustrations in this case. I'm sorry if I was offensive before.)
Annah