>>33753615They originated from R/S/E's original timeline, which was heavily implied to be completely overrun by Ultra Beasts, but not before encapsulating their world's sun into a portable sphere and using it to teleport into a random Ultra Space dimension. Unwittingly, they fled into Necrozma's Ultra Space, and their sun-sphere was devoured by Necrozma after awakening from its latest millennia-long hibernation cycle. During an attempt by the Ultra Space humans to retrieve the energy source, it fled into our world as a last-ditch effort to survive.
Without this energy source, the human-based society in Ultra Space will eventually be unable to support itself. However, their auxillary power sources will last hundreds of years, and the Ultra Space humans have used that time to almost exclusively develop their offensive capabilities and teleportation technology, developing both UB-Adhesive and their giant ring-shaped teleporter in the process. However, said teleporter uses immense amount of energy each time it is activated, so it can only be used an extremely limited number of times.
Ultra Recon Squad's ultimate objective is to retrieve Necrozma from our dimension and return to Ultra Metropolis, no matter the costs. Because they detect it hibernating underneath Melemele Island near the beginning of the game, they literally are ripping off huge chunks of the island in an attempt to get at it.