Wait a minute, @Black Prius. Which battery are you asking about? Neither battery can be just swapped out. The 12V batteries are not the same size for one thing. However, the cells from a NiMH 2016 or newer traction battery will work in a Gen 2 or Gen 3, but you'll want to use all the cells so they match each other.
Trim Two ONLY (not Two Eco), yes the modules can be used. It has NiMH. All other trims have Li-Ion modules.
It is a pity because I have the opportunity to buy cheap with Prius 2016 and I wanted to mount it to my Prius 2010. I currently have 40% battery life
I just realized you are in Poland. The batteries in 2016 Prius vary by country. The advice I gave was for the United States.
IIRC, in 2020, only the AWD version has NiMH. I wasn't sure about other changes from year to year. So, rather than specify trim, I specified chemistry. But for 2016 specifically, yes, you're absolutely right.