No, it’s not okay dude. Mental illness is not an excuse. You don’t get to play that for sympathy to distract from the fact that you did an asshole thing and don’t want to be told that you’re an asshole. Talk to her and break it off correctly. If she isn’t understanding then okay, she just isn’t, but either way you’ll be done and she won’t have this bullshit “what the hell happened?” pinging around in her brain.
I have a couple things diagnosed and the way I see it is mental illness and other stuff (like how you were raised/family dynamic) may be an explanation sometimes, but it is not an excuse. You may have an issue with confrontation stemming from anxiety or whatever you have been diagnosed with but that doesn’t mean you get to use that as an excuse for not being honest. You have to learn how to live and take responsibility for yourself.

Talk to her and simply say “hey, I have enjoyed being with you but I have realized I don’t feel like I’m in a good place to be with someone. I have some things to work on personally.” The conversation will most likely be more than that, but that’s the gist of it. Don’t make excuses, don’t try to make her feel bad for you to avoid her being mad. Just tell her and let her say her piece and accept it. Use it as a learning experience.

Also go to therapy if you haven’t already. Find a therapist who will work with you to learn how to work through things that are hard, like confrontation. Plenty will provide “homework” and scenarios to work on together. You don’t get to take your struggle out on others just because you don’t know how to work through it. Mental illness may not be a choice but you do have the choice to seek help. Therapy can do a lot of good if you make an effort and find the right therapist.