its probably because the code uses national dex and alolan forms arent registered in national dex as a seperate unit. Rather assigned the same no. as their orignal counterparts
im having the same broblem too if anyone finds a solution pls send me a link