You're not doing anything wrong. Groove Clip Looping just does that sometimes.
It tries to guess how many beats are in a clip, and usually guesses wrong. It's an easy fix, though.
Open the Loop Creation view.
If your song is 4/4 time, we know that 4 measures should be 16 beats.
The Beats In Clip window probably shows around 20 beats. Change this value back to 16, and you should be good to go. You may need to play with slicing to get it spot on.
For what it's worth, MIDI groove clips are much more accurate. It's easier to assemble your loops in the MIDI track, then bounce the complete track to audio.