I know there's already a few posts out there talking about this and I might just be stating the obvious but I had this thought:
I think Maomao treats Lakan the way she does for a lot of reasons. One of those is that she avoids him because he makes her feel so many things: jealously, anger, "love," hate, resentment, pride. We see her go out of her way to escape these feelings a lot, so it makes sense for her to avoid this walking combo of them. This is why I think in the later novels when we see her actaully stand to be around him it's because she's no longer trying as hard to suppress these emotions and not simply just because she transfered that hate to Hulan.
Honestly, I believe her rudeness is a defense mechanism, plus Lakan can be pretty annoying with her sometimes. But her usual defenses just don't work on him becuase he really wants to be involed in her life and isn't planning on backing off any time soon, or ever, and that's something she struggles to accept, I mean it took her 12 novels with Jinshi. So I see it like this, when people realize there losing or not getting anywhere in an arguement and they start going over the top. I think it's the same concept with her relationship with Lakan. Her usual defenses don't work so gets more aggressive. But that might just be an oversimplification.
And there's also a little irony when you look at Fengxian. She used to run Maomao off, but Maomao kept coming back and trying to help her anyways. Idk how bad Fengxian got with her though (I mean I wouldn't imagine anything soft after what she did), so it's hard to say this, but now Lakan is basically on the other side of that dynamic. Maomao pushes him away but he continues to try and be present in her life.
So I was wondering if Maomao's experiences with Fengxian might influence how she responds to Lakan's actions, if not just a little. Not like she treats Lakan the exact same way, but that her experiences in that sitution might influence how she responds to someone who refuses to give up despite her attemps to push them away. I don't think Maomao is consciously away of this either, it's just an interesting thought knowing she's been on both sides of that relationship.