My sister was diagnosed with Obsessive-compulsive disorder always needing to perform rituals. Are you familiar with OCD?
I do not have a lot of knowledge about it.  I frequently read that more and more children are being diagnosed with it.
My sister started exhibiting some of the behaviors as a child always needing to wash her hands or turn a light off 3 times. She says that she is unable to control theses thoughts until she does the ritual.