Under the book’s analysis, why is «أَيُّهُمْ» built here?

Relative Nouns — Ṣilah, ʿĀʾid, Forms and Syntax