>>58194963I believe Ash was supposed to win Kalos and XYZ was supposed to be the end of his journey. That's why he has his biggest regress personality-wise from gen 6 to 7, so the whole school setup makes sense. It was supposed to be a new character.
Alain was being set up to be the final boss and they just made him and didn't put too much thought.
With their insistance on making Ash losing Kalos, they should have made Ash beat Alain in the semi and then losing to Sawyer in the final battle.
Oh well, roads not taken...
As for Alain's return, they just overestimate his popularity. They thought people would go crazy after him.