You have been improving. I remember when you were apprehensive about even talking to girls. And now look - you were texting a girl and trying to hang out with her. And after you're done reading this post you will have improved even more. Because I'm going to give you an idea of where you went wrong and how to handle it for next time so you can succeed.
You mentioned that she was leading you on, however I highly doubt this was the case. In your previous posts, you mentioned that every time you texted her, she was busy. She was really hoping that you'd get the hint instead of having to be mean to you. But when you didn't stop texting her, she told you she had a boyfriend, which is a very clear indicator that she's not interested. If a girl is interested in you, she's going to make time to see you! She's going to be excited about seeing you.
So where did you go wrong? When you text a girl to hang out, you say "Hey what's your schedule like the next week?" If she gives you a time she's free, then you make plans with her for that time. IF she flakes on you the day of, then you say "no problem." Then say something like "Alright, just text me when you're free and want to make plans and we can go from there." You're throwing the ball in her court. If she's interested then she's gonna text you. If not then you probably won't hear from her. This is effective because it prevents you from chasing her which is unattractive to girls. Sounds like you were texting her a lot asking her to hang out.
Also you handled it wrong with your reply to her mentioning she has a boyfriend. A guy who gets a lot of girls would just not give a shit. He'd stop replying and move on to the next girl. You started questioning her about it and showing an emotional reaction which shows her that you're needy. By this point, she's totally in control of the interaction and like I said....you're chasing her.
Keep working on your fundamentals! That's the important part right now.
Here's some reading material that I think you'll find helpful:
https://www.girlschase.com/content/what- ... reschedule
https://www.girlschase.com/content/what- ... irls-flake
https://www.girlschase.com/content/why-c ... omen-doesn’t-work-and-why-persistence-does