For some people, simple changes of environment or lifestyle can permit the body & mind to heal itself. In this way, perhaps depression or anxiety can be the body's signal to make a healthier change. Perhaps this might be the "normal" role of negative emotions, to influence us to make a necessary or protective life change.
Many medical illnesses feature an over-reaction of the body's natural protective mechanism. In autoimmune or inflammatory disorders, for example, the body's protective mechanisms attack and harm normal tissue. It is not a matter of simply making a positive life change -- the protective mechanism itself is malfunctioning. In treating such disorders, steps have to be taken to change the abnormal inner process, not to change the environment.
Likewise, in depression or anxiety disorders (and probably many other types of mental illnesses too), the mind's normal tendency to experience negative emotion, perhaps in reaction to adverse events -- malfunctions, and becomes out of control.
There are a variety of treatments:
1) wait for the symptoms to pass. This is painful, the symptoms may be highly disruptive while they last, and they may cause other life disruptions that could take many years to repair.
2) Learn mental or behavioural techniques to calm the mind or control the symptoms. So-called "cognitive-behavioural therapy" is one of the most well-researched techniques for managing symptoms of the mind, and the results are very robust.
3) Medications. The various medications for mental illnesses can help substantially. Some of them relieve symptoms immediately (e.g. benzodiazepines), while others are thought to be "disease-modifying agents" that can relieve symptoms in the long-term and prevent relapses (e.g. antidepressants, mood stabilizers, and antipsychotics). This reminds me of the treatment of inflammatory diseases such as rheumatoid arthritis, in which there can be immediate anti-inflammatory treatments (e.g. prednisone), while there are long-term treatments which reduce relapses (e.g. gold salts and immunosuppressives). With arthritis, treatments such as prednisone can be powerful reliefs, but should be minimized because such treatments weaken the body if used frequently. Similarly, the acute treatments in psychiatry, such as benzodiazepines, are very important, but can be counterproductive if used long-term, unless an individual patient cannot manage without them.
A supportive relationship with a therapist can be a powerful source of comfort, safety, security, and a framework in which to focus on growth & wellness. There are many styles of therapy, some styles perhaps more theoretically dogmatic than others, but I think the most important features of a healthy therapy relationship are feelings of safety, confidence, reliability, feelings of being heard and understood. Sometimes this supportive relationship itself becomes the strongest factor leading to recovery.