Let's be clear: unsolicited teaching or advice is rude. There cannot be a "better way" of being rude. When someone treats you badly, trying to be a good girl and please your aggressor is not the right thing to do. It won't work. They are not saying all that to make things better, besides, they don't have the first clue about how to go about that. You don't need to be rude back, of course... just leave.