The relative and interrogative pronouns (quī, quae, quod) and (quis? quod?) are originally of the same root, so their older forms overlap in many places. The majority of this post will cover features of Latin you might only live to see once, or never.
The archaic genitive singular of this root is quōius, and the archaic dative singular, quoi.
The form quī is alternative of the ablative in all genders, though most often appears as an adverb (quī, how, in what way, inanway–using the same semantic field as the Greek ὅπῃ), or as quīcum, with whom? However, there are more general instances, even in classical Latin, for instance:
Which chest did the spears pierce: quī pectōre tela / transmittant (Lucan, Bellum Civile 7)
The archaic nominative plural, quēs, is only found in early Latin, though the archaic dative/ablative plural quīs is found in classical poetry.