What can I do if my advisor wants me to keep working, even while I'm on medical leave for severe depression?
There is only one suitable course of action I recommend, as an advisor and a physician. Stop with anything that has a potentially detrimentally effect on your health and focus on your treatment (thus if you believe so also your MSc commitments).
Indeed, your work is likely contributing to your depressive symptoms (irrespective of the differential diagnosis between burnout and depression; e.g. Bianchi et al, Soc Psych Psych Epidemiol 2015).
Much more importantly, if you do not treat yourself now in the best possible fashion you might fail the treatment and even face substantial complications early or later, even life-threatening ones (e.g. Mann, New Engl J Med 2005).
I would definitely inform your physician that your advisor's attitude is likely a contributory factor to your condition.
Finally, notify any oversight committee at your institution, as individual or organizational issues impacting on your depressive symptoms could and probably should be addressed thoroughly (e.g. Theorell et al, BMC Public Health 2015).
You are on sick leave. Take it and take it seriously.
You didn't take the last two sick leaves seriously, did work, and still remained sick. It's just as if you had a broken foot and kept walking on it and asked why on top of the first fracture not healing, now you have a stress fracture on the other foot.
So:
Do not go to school for any reason except one last time to pick up personal items. Better yet, send a friend to pick them up for you.
Set your e-mail auto-responder to "Émile is currently on leave and will return on xx/xx/xx and is not answering e-mail. Questions regarding the xxx lab should be referred to [email protected]."
Your telephone answering machine or voice mail should have a similar message.
Do not check your e-mail or voice mail. You will tempt you to break your isolation for just "one last emergency" - but it will quickly become a habit. They can fight their own fires and find their own copy of that datasheet you tucked away.
Go to what we Americans joking refer to as an "undisclosed location" (it can be your apartment, but it can also be out of town/country) and treat your illness seriously. Again: don't pick up the phone or e-mail. Set up a separate e-mail address or skype just for your close friends and family. Work on healing.
I am not an expert of any description, but I have seen situations like this before, especially in academia. If your situation is like the ones I've seen, the following advice is apposite. Of course, it may not be, so take it for what it is.
It sounds like you are suffering from a burnout, or something very similar. A burnout often happens when the patient feels trapped in his work environment. Something is convincing the patient that there is "no way out" but to keep working. In your case, you feel that if you don't work, you will lose your funding, lose your master's, and lose your career. It's all or nothing and there's no escape.
The first thing to realise is that there is always a way out. If you continue down this path it can kill you (that's not an exaggeration). It's certainly not going to get better. That's the choice: get your master's later with a different supervisor, or continue to destroy yourself until you end up in the hospital. It feels like there's no way out but there is.
The important thing, and most difficult thing now is to control how much you deal with your professor. He is a major factor in your illness, and you need to drastically reduce the amount of interaction with him. Tell in no uncertain terms that you are on sick leave, that you will not be checking your email more than once a week, and you will not meet him face to face for the foreseeable future.
He may not believe in mental illness (which really sucks for you and you have my sympathy), but that just means you need to assert yourself more. Of course, that's difficult and that's a big source of your problem, but it's the only way you'll get healthy again. Your therapy is going to require plenty of energy, and if you spend it all on the interactions with your boss, you won't have any left.
Use your sick leave to get better, not to worry about the future. There is a time to start thinking about reconstructing your professional life, and it's several months from now. You don't have the energy yet.