The act of writing makes you a writer. Period. Creating a writing practice helps, but whether you write via a practice or in fits and starts, you’re still writing.
Publication makes you a published writer, but to be a writer, you simply have to write. So, let’s take a moment and examine our language around our own writing. If you write, you are a writer. In your mind you might not feel like a writer-writer until you’re published, but until then, get in the habit of calling yourself a writer anyway. Later, call yourself a published one if you like (though, don’t actually do that outside of your own head; it looks a tad cringey when it’s written out in a bio), but be clear that by writing you are a writer.
Yet, the simple act of doing the work is one of the hardest things. So may hopeful writers ask those published for “tips'' and such and anytime anyone has ever asked me about tips for writing, I have patiently and curiously listened to their particular challenges they believe they must first overcome in order to do the actual writing (some valid, some total fabrications of the mind in order to stall and/or self-sabotage), but always eventually told them each the same: listen, you and I can talk about it all day, but eventually you’re going to have to sit your ass down and write. And you might not feel like it. Figure out a way to make whether or not you feel like writing that day be irrelevant.*
To be sure, the best part of sitting down and doing the work in any creative discipline, is that once you make a practice of it that muscle gets strong fast and your mind sort of slides into place at the designated time, so you won’t necessarily have to feel like you’re fighting yourself every time.
* I say that, but also acknowledge life happens and chronic illness/pain happens and spoons are a thing, and I’m not suggesting you ignore any of that. We’re talking about calling ourselves out on our internal mind-games we play against ourselves, but not trying to “push through” any of the things that demand our attention otherwise. I get those.