One of my EVs has a rusty hood latch cable that needs to be replaced. It caused the same problem where it wouldn't return enough to allow the hood to latch properly.? After some lubing and working it, I was able to juuuusssttt get it to latch.?
It could be that the battery install involved pushing or pulling on the release cable since it goes right over the top of the battery and could have been in the way.? I'd focus on the cable.
Good luck,
Kent