Before I go onto my theory onto Why Pokemon that should be immune to Ground aren't, I just want to mention that this ALSO counts Levitate and other abilities and such that make a Pokemon immune to ground, this doesn't count Mold Breaker also. This also DOESN'T count the air balloon, it is weather a Flying type or has a Abilities that makes them Immune to Ground that counts. Onto the theory now!
There is Pokemon like Volcarona and Ribombee which both aren't flying type and don't have levitate, because they are flying when you battle with them it seems like they SHOULD be immune to Ground, but they aren't. Using the Flying type and ability Levitate for this, if the Pokemon is flying type they can properly fly above the Ground without a problem since because they are flying type, they shouldn't have a problem avoiding the Ground, and a Pokemon with levitate can just levitate off the Ground to avoid Ground type moves too. Using Volcarona as an Example, without the proper ability to levitate or fly above the Ground they can't avoid the Ground as well making Volcarona vulnerable to Ground type moves. This can also apply to Pokemon that aren't flying but levitating but are still vulnerable to Ground type moves. That's the theory, again back to the question, if there is any piece of evidence that proves my theory wrong then let me know and if there is enough evidence that proves my theory wrong we will just have to wonder why Pokemon that should be immune to Ground aren't and go with the logic of Pokemon :P