Is there a 5e magic/mechanic that could cause an item to disappear/teleport/planeshift on death?

I am running a 5e campaign where my players may encounter the Xanathar. Being the murdering hobos that they are, they may eventually successfully kill him since he is just a normal beholder stat block. He has a couple magic rings, including a Ring of Mind Shielding.

I was thinking of having his soul go into the Ring of Mind Shielding on death and then have the ring disappear to a place he can be true resurrected/wished to life later on.

Would there be a mechanic/spell that allows me to do such a thing? I try my best to make things within the rules instead of just DM ‘it happens because I say so’.

Thanks in advance! The loss of the Xanathar to the realm would be truly disappointing.