Official Riftbound ruling

What happens when I play Hextech Ray on an Elder Dragon while Imperial Decree’s delayed trigger is active and I have an Immortal Phoenix in the Trash? Can I play Immortal Phoenix from the Trash?

You can.

Per the current rules, there is nothing that would stop Imperial Decree’s delayed trigger from triggering Immortal Phoenix. It is a triggered ability generated by a spell; it is attributed a kill action, and thus the spell that generated it will also be attributed the same kill action. The owner of Imperial Decree is the controller of the delayed triggered ability; the player responsible for the kill action is the one who controls the ability; and that same player is the owner of Immortal Phoenix in the Trash. Thus all three conditions for Immortal Phoenix triggering are complete, and it will trigger.

Riot's question and answer, word for word, from theVendetta Rules FAQ and Clarifications

The cards

  • Hextech Ray
    Hextech Ray

    Spell

    Action (Play on your turn or in showdowns.)

    Deal 3 to a unit at a battlefield.

  • Elder Dragon
    Elder Dragon

    Unit

    Any amount of your damage is enough to kill enemy units.

    When you play me, choose up to one enemy unit at each location. Deal 1 to them.

  • Imperial Decree
    Imperial Decree

    Spell

    Action (Play on your turn or in showdowns.)

    When any unit takes damage this turn, kill it.

  • Immortal Phoenix
    Immortal Phoenix

    Unit

    Assault 2 (+2 MightMight while I'm an attacker.)

    When you kill a unit with a spell, you may pay 1 Energy1 EnergyFury RuneFury Rune to play me from your trash.