This is my personal take on why Toyota is hung up on hydrogen fuels.
Japan has no significant lithium deposits, and little oil. They rely on imports for both oil and lithium, creating a national security issue. Like China, they are at latitudes with high climate change impact, so they take that problem seriously, and fossil fuel is out, eventually.
They're between a rock and a hard place. If they build their transport system on lithium batteries, they can be cut off from lithium supply by adversaries.
They have a fantastic public transport system and do not rely on the car, even their kei cars are a luxury. Most Japanese can get where they want without a car, and those who insist on a car are often well-off enough that it's Ferrari or nothing with them.
Japanese car ownership is a big fat hairy deal, again, even a little kei car is like buying an American house, a huge investment in more than just the car. License tests are strict. You often must prove to the government that you have a place to park the car, in Tokyo, before they issue a plate, with all the real estate investment that implies. All Japanese cars are luxury cars. What's a few more yen in fuel costs? If it's too much, take the train, which is world-class.
The best future option for Japan is local hydrogen generation for non-train vehicles. Toyota, the "eldest son" of Japanese carmaking, has been tasked with putting together respectable hydrogen cars.
Toyota knows that the cars will not make much sense outside Japan, but hope to sell them as luxury vehicles to those, especially Americans, who do seem to love Toyota cars and ICE engines, offering them the vroom they like with carbon friendly fuels. Hopefully it keeps the fuel infrastructure alive in the West, and thus the market for future cars. The Americans will reliably buy much larger engines than the ones they normally sell in Japan. Large engines are the point.
The luxury cars, just the Murai, really, are a proving ground for technology that will ultimately power Japanese heavy trucks that currently rely on diesel. Honestly, if you've ever spent time around LNG forklifts, Japan is going for that, but carbon-neutral, because hydrogen. They already have enough technology to make cars go, it's just a matter of changing the fuel.
The trains can also be hydrogen fueled, with the expense spread across many passengers, though Japan has just enough oil for the trains, if needed. They'd rather that all their native diesel production go to trains. All the flagship trains are electric, anyway, but much of the Japanese train fleet is just plain old diesel, and perhaps that can be upgraded to hydrogen if necessary, or not, if that's the only diesel they need. Outside Japan this hydrogen doesn't make much sense. Inside Japan, it does.
Japan is a ship forever at sea, and it values fuel that can be produced on board than it does any fuel, oil or lithium, that must be dragged across the waves. Of course it is Toyota who has been called before the government and voluntold to sort something out for passenger cars, and trucks. Especially trucks.
Other nations are in similar positions to Japan, lacking lithium and oil, and worse, wealth to buy their way out. They, too, can build out train networks for efficient public transport and minimal use of oil, while the remaining luxury of personal cars and the necessity of heavy trucks can be met with locally made hydrogen fuels. The high fuel cost of hydrogen powered trucking can be split across many customers, making it make sense. Toyota has its eyes on these nations as customers in the future.
Of course, to us in the wealthy West, it all seems a bit silly, as though Toyota has gone mad. They have not. Somehow, the Americans have massive lithium deposits in the desert just when they need them. Just like they magically had oil, too. But Japan is not so fortunate, nor are many others. Toyota knows what they are doing.
I don't think it is so much that they are "hung up" on hydrogen as it is that everyone else is hung up on battery electric. While EVs sound nice in theory, there are still absolutely monumental hurdles to them replacing ICE cars for every use case. At the end of the day batteries simply only have a fraction of the energy density as gasoline. A chemical reaction that makes a few volts per cell and needs thousands of them is just going to have issues scaling beyond casual use. An EV works great in a city for short trips, but for people that live in places like America's "flyover" states, I've done 4 hour road trips where I have fuel range anxiety in a gasoline powered car and I had a friend from Colorado who wanted to drive down and visit but couldn't because she has an EV and there simply wasn't a reasonable route for the drive. Personally, I think hydrogen is a better solution; everyone got wrapped up on battery EVs and went all in on them, but even with advances in batteries and charging speeds, they still can't replace a very large percentage of cars out there today and the technology required for them to do so requires fundamental changes in known electrochemistry. >5000 lb compact cars really aren't sustainable.
Wouldn't count hydrogen out yet as it's not just for cars.
The UK and Europe (particularly Germany) are also investing in hydrogen but less so for cars, London has a few hydrogen busses though and cheaper production could mean more popularity.
There is a demand for Natural Gas replacement, as heating and cooking is very common in some places (78% of UK homes and 50% German use it for heat).
Replacing Natural Gas network with hydrogen is cheaper and quicker than conversion to heat pumps (it'll likely be a mix). UK gas network and storage has been converted to deal with hydrogen and has had successful trials, this winter UK could start blending upto 20% hydrogen into the gas supply. 100% hydrogen trials to start in couple years.
Green hydrogen is a great store for renewables as well. Solar and wind are built above required capacity (due to variability), this means the vast amount of times there is excess energy. Pink hydrogen (nuclear) is a potential biproduct from SMRs.
Lithium has been found to be in grannet and deep groundwater in UK, so it's not just mines. Australia is a huge producer of lithium as well, far more than China. But being energy independent is a huge boon.