One thing I'd say is to echo what other people have said. Have an idea
If you just try to sit in front of a screen and expect to write code with no idea of what you want to write, you'll quickly get overwhelmed and lose all motivation.
Come up with a problem you encounter daily, or an idea, doesn't have to be unique and can be done 1000 times already by other tools or apps, just make it simple to start with. Then break it down in to it's most basic components, such as it's main UI, inputs, outputs and then come up with the ways in which those need to talk to each other. As you learn the basics of object orientated programming, you'll be able to expand upon these initial diagrams/ideas and improve them.
Another thing I'll say is keep it simple. Don't try and write the cleanest and most efficient code first time, it will never happen. 10 years of coding professionally and I'm always refactoring code I've written several times as I think of ways to improve it. Every person I mentor, I always say the same thing, just write code to begin with. If it looks messy, if it is bloated and full of unused variables or methods, if it's inconsistent, don't worry, just keep writing and get something working, and when it's working, then worry about improvements.