That's a pretty understandable reaction if you consider how important it is for young teenage girls to feel accepted, wanted, and desirable. So much of our society stresses that girls have no value outside of being desirable partners so a lot of girls are taught that that's what their self worth is based on. It doesn't justify her being mad at you but it does somewhat explain it. It seems like she's reacting out of hurt and lashing out at a person who will accept and love her without any ulterior motive. It often feels "safer" to take out those feelings of hurt on someone you know for sure loves you.
Give her room, and then be there to support her when she's cooled off. This is one hell of a bad experience for her. What an awful and inappropriate thing for her boyfriend to say, let alone do.