It is theoretically possible to get a job as a developer in Japan with no formal education. But it’s likely not going to be easy, and not everyone is going to be able to.
A good approach is the one that you’re already taking: start learning on your own in your spare time. This not only is a low risk approach, but also helps ensure that it is a career you’re actually suited for. Building your own projects can be a good way of demonstrating your aptitude for development, and if you have something stellar, it can be enough to land a job.
Another approach is to look for opportunities to use programming to solve problems within your current job. Most jobs involve some sort of manual tasks that could be done more efficiently using software. It of course depends on the nature of the job, but if you manage to automate things, it’s possible that you can slowly change your role within the current company to be a software developer. Even if you don’t get that far, any practical software like this you create would give you a great way to demonstrate your abilities when applying for jobs.
Another route is to go with a coding bootcamp. I know people who have taken international online ones and got a job in Japan, and also people who attend the Japanese based ones, Code Chrysalis and Le Wagon Tokyo. Attending a bootcamp is not a guarantee you’ll get a job, and so it’s a substantial investment, but if you hit your limits going at it by yourself, it is something to consider.
A good thing is that if you have a work visa, likely a company can hire you right away. This makes it easier for you to change careers than if you weren’t in Japan yet and looking to relocate here. Because you have a university degree, renewing that visa shouldn’t be an issue.