I am wondering why is it so hard to migrate to another programming language?
Among other things because of the immense costs: Migrating millions of lines of code to a different programming language costs an immense fortune.
And let's face it, there would be zero benefit in doing so: Will the software run better just because it was ported to Java or C++ or something else? No.
Will it be more stable? Actually, the opposite will happen: Rewriting it in a new language will result in the software having a lot of newly introduced bugs; bugs that the old code base simply didn't have anymore, because the bugs had been ironed out over the DECADES (!) that the software had been in use. It is safe to assume that the "legacy" COBOL code base is as stable and as rock solid as it gets.
It is almost always counter-productive to rewrite a software in a new language. Google up on the disaster that Borland ran into back in the day when they decided to re-implement a major product from scratch -- it was one of the reasons why the company eventually went down the drain.
It simply makes more economic sense to train developers in the old system than to rewrite software that actually works. We've had this scenario before, back in the late 1990s. Everybody was looking for COBOL programmers because of the Y2K issue. Heck, back then I also attended a Y2K training where, among a lot of other stuff, I also picked up mainframe technologies like MVS, SPF, JCL, DB2-SQL - and COBOL. Even in 1998, these things were already "legacy" technologies -- and they are still around. In the meantime, popular languages like PERL have risen to absolute hype - and then quickly sunken into oblivion. Unlike PERL, which has mostly disappeared from everybody's radar (except for the OTRS and OFORK people), COBOL is still a mainstream language in certain key industries (especially in the financial sector).
Believe it or not, COBOL actually is a nice language to write. As some people say: "Programming in COBOL is more like writing a book than it is actual programming." True. But COBOL listings look nice, and they read nice. The readability is a big reason why the software is also as maintainable as it is -- and why those millions of lines of COBOL code are still around today, and will still be around when all of us have reached the retirement age.
Fortran and also good old Pascal are also still around in several sectors. Fortran is still widely used in the scientific sector and also in aerospace engineering -- where they also still use ADA a lot. Pascal can still be found in robotics or also in the scientific sector. And you wouldn't believe where you would still find some very exotic BASIC dialects; PowerBasic, for example, is used by one of the most popular accounting software products in the US. The quite successful "Crypt of the NecroDancer" game was written in Mark Sibly's "Money X" programming language, which was a success to BlitzMax, Blitz3D and BlitzBasic. But when you believe the Internet, BASIC died with the home computer era of the 1980s, and we should all be using Python instead today - which, I will keep on saying until my dying day, is also just another exotic BASIC dialect.