Aaaaaaaaaaaaa, I've been replaying Ultra Moon and I've been catching every legendary possible through the ultra wormholes (only rayquaza to go), and I noticed something when I caught Zapdos. Normally I play with the music off, but occasionally I turn it on for no reason and then it gets stuck in my head for a year. But, here's the thing I've figured out. When you encounter a legendary from a previous region, it plays the encounter music from that region.
This is hands-down my favourite little detail about Pokemon, ever.
Articuno/Zapdos/Moltres: Random Encounter theme from RGBY
Mewtwo: Kanto Legendary theme from XY
Raikou/Entei/Suicune: Legendary Beast theme from Crystal
Lugia: Lugia theme from HGSS
Ho-oh: Ho-oh theme from HGSS
Regirock/Regice/Regitsteel: Regi theme from RSE
Latias/Latios: Random Encounter theme from RSE
Kyogre/Groudon/Rayquaza: Weather trio theme from RSE
Uxie/Mesprit/Azelf: Pixie Trio theme from DPPt
Dialga/Palkia: Dialga/Palkia theme from DPPt
Heatran/Regigigas: Rotom/Legendary theme from DPPt
Giratina: Giratina theme from Platinum
Cresselia: Random Encounter theme from DPPt
Cobalion/Terrakion/Virizion/Tornadus/Thundurus/Landorus: Legendary theme from BW/B2W2
Reshiram/Zekrom/Kyurem: Tao Trio theme from BW/B2W2(one version instead of subtle differences like the originals)
Xerneas/Yvetal: Kalos Legendary theme from XY (Zygarde uses this theme too but it's found outside of Ultra Space)