Both katakana and hiragana (kana) are simplified and syllabatic forms of various kanji. Kanji are largely (but not exclusively) Chinese in origin.
Katakana is often used for foreign or loan words and onomotaepia but not exclusively.
It’s complicated and sometimes makes no damn sense.
That’s coincidence more than anything I think. Ka in both forms has the same root kanji (加) as does ri (利). Many kana don’t share the same kanji root between the two writing systems.