Rhyming in modern Mandarin
As a native speaker, I don't think yan and huan rhyme, but yan and xuan do.

I think their endings can be written in IPA as:

yan - ɛn

huan - ɑn

xuan - ɛn

Only the last vowel and following coda count as 韵, the [u] in huan and the [ɥ] in xuan don't matter.