A mental disorder is a mental health condition.
It may affect the decision of whether to prosecute a person or their ability to appear in court and understand the court process. A mental disorder could also affect the sentence that a person might get.