This is because urea forms cuprous cyanide, which is volatile, and upon decomposition releases copper that burns with a green flame.