One of my relatives was doing itikaf. And for some reason, they weren't able to complete doing it, and now they're behaving like a mental patient and saying stuff like "I can see a person (Jinn) wanting to kill me". And much more. I took them to a mental hospital but the doctors don't seem to understand what happened, and my relative didn't get well. Ultimately I think it's really some Jinn(s) attacking them.
Does that mean not doing itikaf fully will cause attacks by Jinns? Also, in what cases a Jinn can attack a human? Is there any way described in the Quran to save myself (and my relative) from them?