>>30053787easy, they got the mega stones from kalos, either by steve gifting the extra ones that he already has to trainers or delivering from the store that sells you one in luminose, in the case of the evil team smuggling is an option, or a rare undocumented occasion when they can be found outside of it, there are tons of ways of explaining it that doesn't require multiple dimensions, it just happens that that theory got really popular really fast