Another thing I find myself doing is giving an excuse for saying what I've said, sort of saying sorry it was my fault. Sometimes I even apologise and she thanks me.
You can see what is wrong with this right? How
unhelpful this is for both of you? These are like mind games, with the risk being that you start to believe some of the things you are apologizing for.
But I end up feeling that I'm a villain.
You are NOT a villain. BPD can be a terrible and complicated illness. One of the best things you can do is read about and understand it. Then learn some new skills (this website has tons of good info) for relating to a pwBPD to reduce conflict. And start practicing boundaries to keep yourself safe.
It sounds like you may be "validating the invalid". Don't apologise (directly or indirectly) if you have done nothing wrong. Doing this validates the invalid, and just reinforces their dysfunctional behavior.
https://www.bpdfamily.com/content/communication-skills-dont-be-invalidatingIs it that you "sort of say sorry it was your fault" to keep the peace? Is it a survival strategy? pwBPD have distorted thinking, and you really don't want to validate that distorted thinking, or it is going to continue, or even get worse. What you can do
instead, is validate the emotion you perceive them to be experiencing, and empathize with them. That is a healthy communication skill. But apologizing all the time to avoid conflict could make you feel either like a doormat, or insecure about yourself.
Does this family member live with you?