It sounds like you've tried to resolve this on your own. Have you tried asking him to stop? Explain that you have nothing against him as a person. And you would appreciate if he would leave you alone because you don't need this drama in your life. He may listen if you're calm and show him that you're not interested in fighting or anything. If you two go to school together, I would suggest talking to the principal there. Then they can talk to him about it. He may need a suspension or something to show him that it isn't ok to treat people this way.
If you aren't in school, it may be time to talk to his parents or the police if he's older. You've done what you can to get this under control. But he obviously isn't open to listening to you. And he poses a threat to your physical safety right now. You could show the messages to the police and file a report. Then try to get a stay away order so he's not allowed near you. If he does try to come near you, a simple call to the police will land him in jail.
Basically, do what you have to do to keep yourself safe. I highly discourage provoking him further by responding to tell him that you aren't scared of him. That only makes him angrier. He's going off based on jealousy and hurt. Hopefully he'll cool off soon if you don't give him any reason to get angrier with you.
Good luck, I hope this gets resolved soon.
-------
kid, I wrote back,
all lovers betray.