Metal 'X' is Lithium (Li), which when burnt in air forms only lithium oxide (Li$_2$O) because it does not form a nitride in air. On the other hand, Metal 'Y' is Sodium (Na), which forms both sodium oxide (Na$_2$O) and sodium nitride (Na$_3$N) when burnt in air.