I think I have figured out the issue with the ability glitch, I just don't know how it'd be solved.
Freelectric (if someone's tests prove me wrong, feel free to shoot this theory down) is the ability you are always given at the beginning. No need for quitting and restarting until you get it. It has nothing to do with level and isn't learnable.
So why do you not have it? Loading a save. Freelectric is a unique move, only belonging to Red's Pikachu. This means it isn't available to other PIkachus, they instead can receive either Static or Lightning Rod. When you start out, there is nothing you can do to lose it, but I have noticed upon loading my save, I don't have it. Here's what I think is happening. The game doesn't know that my Pikachu is a special Pikachu, it just assumes I'm like the rest. Therefore I can't have unlearnable moves. When the game boots up your save, the game checks your ability slot. It sees you have a Pikachu and therefore knows you can only have Static or Lightning Rod. When it doesn't see either, the game just assigns a Pikachu ability at random (which is why you get a random ability with each reload).
So what's the solution to this issue? Idrk. The best advice I can give is don't load a save, but when the time from the beginning to the fight with Dawn is around an hour and a half even if you skip through the dialogue, that's a tough ask.
This is the best I could come up with after a little testing. I'm not the best at games so even if some of this is right, chances are I'm mostly off-base. Good luck!