She asked you numerous times if you were okay, an every time you said yes, not to bother her. Because you didn’t want to bother her, you walked home alone. Next time, speak up.
You told her you were fine with walking alone multiple times. Why didn’t you say, “No, I’m not cool with this. We had an agreement to walk back together, please walk back with me.” Or “No, can you please walk me home first?”
In future, speak up and don’t play cool just because she’s with her boyfriend. Care about yourself more than whether your friend is bothered or not.