Sure.
And after you have enough Gym Badges you will become a Gym Leader. Then you have to beat Challengers and soon you will become a Pokémon champion, then you beat more challengers to become a Professor! This system makes you feel that you have stepped in the world of Pokémon aiming to become a Pokémon Master!