The Pokémon anime always had an interesting way of handling its villains. First, the Team Rocket trio would bug Ash and his friends regularly; it got to the point where they could be called members of the main cast. Every once in a while, however, Ash would have to handle the complex schemes of a more dangerous evil group; the Team Rocket trio would also find a way to get mixed up with this new threat. This cycle would repeat itself every time Ash entered a new chapter in his journey, so fans always had a good idea of what to expect.
Source:https://www.cbr.com/pokemon-horizons-new-way-to-recurring-villains/