Hi,
I am sorry to hear that. Please remember that you are not alone and you have the right to seek help. Your mental health is extremely important!
Firstly, I would suggest reaching out to mental health support at your university. It might be incredibly helpful to talk about your feelings, worries, and issues with someone. No one will give you better advice or support than a professional who can greatly understand you. Also, there is nothing to be ashamed of. Struggling while being at university is completely normal and that is what welfare services are for.
Secondly, consider talking with your lecturers. You will be surprised how understanding and compassionate they might be. There are opportunities for 1:1 support or deferrals that you definitely deserve.
Take care,
Julia