How do I detach myself from a toxic friend?

There's a girl at my school that I became attached to last year. We were similar in a lot of ways. 5 months into our friendship, she started releasing her anger on me a lot. She screamed at me for little things. She used to tell me about her problems and life and I listened patiently but, when I shared my problems, she just brushed it off. We used to talk a lot over text but it eventually stopped. I'm the type of person who just can't let friends go once I've made them so I reached out and tried to address topics to resolve our friendship but the response I got was- "I'm just trying to distance myself from certain people, and I think I made that clear". I understand that this friendship is toxic but I just can't seem to let her go. I always considered her a best friend but she never even said we were friends. She referred to me as a classmate. What should I do to let go? (I don't know if im doing something wrong. I always talk to her politely. I also have to be with her in this class for the remaining year so... I don't really want any conflicts.)
How do I detach myself from a toxic friend?
How do I detach myself from a toxic friend?
Post Opinion