I have no idea if it can learn Relic Song and it is the only way for it to change into its Magician form (which I honestly like better)
D. Meloetta can learn Relic Song and it does change it form once the move is used in battle.
Where/when though?
Delta Meloetta learns relic song by a move tutor in the Alpha Temple of No Man`s Land, before that you must have defeated Reukra in the Throne of Hegemon.