Why do guys lie about having sex with a girl, when they know themselves they didn't have any sexual contact?

My friend was talking to some guy for awhile now and when they finally hanged out he acted like they were a couple and things were real . A few days after they hanged out, she had found out that he had told all his friends that they had sex and all this other non sense. I just wanna know why he felt necessary to lie?
Why do guys lie about having sex with a girl, when they know themselves they didn't have any sexual contact?
Post Opinion