Hi there
Firstly it's less likely that some medicine prescribed by a MBBS doctor can further lead to lack of sleep. This lack of sleep is a part of syndromal illness that started over a period of time. Let us put across the symptoms as follows
1. Heaviness of head/headache
2. Feelings of depression
3. Suicidal thoughts
4. Worry
So for these symptoms she surely need to see a psychiatrist (a psychiatrist may further refer to psychologist if there is need of psychological assessment or treatment).
Taking alprazolam on own is not at all advised. Take medication only after consultation. Don't rush to stop medicines. The treatment might be longer than you are expecting.
Next Steps
Consult a psychiatrist for detailed assessment and treatment
Health Tips
It's more important to be healthy and at peace. Duration of treatment is something that can always be discussed as case per case.