I've done similar things to girls who have rejected me romantically; in one case, it was with a female friend of mine who took a couple of months to finally tell me she didn't like me that way. In this guy's case, he's being pretty immature, but I still share his frustration. It's a defensive mechanism; he's most likely trying to avoid the pain and frustration of being around someone who can never give him what he wants, in this case you. Trust me, I've done the exact same thing. I think the best thing to do with him is to tell him plainly that you will never be romantically interested, but genuinely value him as a friend. Perhaps he thinks you were using the "friend" excuse as a means to kindly reject him. The badmouthing of you by him, however, is inexcusable. At the very least, confront him about that.
_________________
Neurodiverse score: 139/200
Neurotypical score: 62/200