If you don't mind me saying this, one thing that gets overlooked often in situations like the one you explained is that the team is part of the system that needs modernisation.
In fact, the team needs to lead the modernisation effort. It needs updating before the rest of the system can be.
From your explanation it sounds like you expected to find a modern and skilled team maintaining a legacy project. That is not at all so frequent. If the project is legacy, most often is because the team also is outdated.
So, obviously you can just switch jobs. And if you're getting sick from it, then you should by all means leave this job.
But then again, if what you actually want is to make this job work, then my suggestion is to:
1. Get the whole team together and evaluate their situation. Make a list of the skills the team is lacking and the knowledge updates needed. Make them participate in this so that, at the same time, you can evaluate their attitude towards the whole thing.
1.a. If the team does not want to update, then there's no successful path and I would suggest leaving.
1.b. If the team is receptive, then go ahead.
2. Meet with whoever needs to authorise it and get them to commit to providing both time and resources for re-training the team. You will need a plan, a timeline, and achievable goals.
3. Start as soon as you can. Focus first on basic infrastructure. Any tools, processes, skills, that are generic and widely applicable. Then go for more specific ones directly related to the project's technologies.
The team may need some rearranging too, but try to keep this at minimum so that they can be confident that all of this is strictly related to a technology and skill update, and will not imply any sort of job insecurity or competition.
You may have noticed that all of this is mostly people management. If this is not something you'd like to do, then the only option is leaving. The job you're in right now is clearly one of people managing and not so much a technological one -though is still requires knowing and choosing the technological goals to seek, obviously-.
If you do follow, then who knows what will happen. But if things go well, you might expect to see some results in around 6 months or so, depending on how large/small the team and project are.