Start with writing integration tests. Worry about touching the code only after you have a full test harness. Using an external tool like Playwright, Cypress, or Selenium you can write the tests in a language of your choice without touching the code.
Deploy the code into a staging environment (make a copy of prod). Kubernetes might be useful to try to package the application in a replicable manner. Then get the tests running on CI.
When the tests cover literally everything the app can do, and everything (tests/deployment) are running on CI, changing the app becomes very easy.
Your junior coders no doubt have been yelled at many times for attempting changes and failing. When they begin to understand that change with breakage is possible, their confidence will increase, and they will become better coders.
Resist the urge to change the application at all until you have tests.
Deploy the code into a staging environment (make a copy of prod). Kubernetes might be useful to try to package the application in a replicable manner. Then get the tests running on CI.
When the tests cover literally everything the app can do, and everything (tests/deployment) are running on CI, changing the app becomes very easy.
Your junior coders no doubt have been yelled at many times for attempting changes and failing. When they begin to understand that change with breakage is possible, their confidence will increase, and they will become better coders.
Resist the urge to change the application at all until you have tests.