Hello,
Getting back with analysis of the behavior.
In fact the behavior is expected with STM32H7B/A devices (not the case of STM32H74x/5x/2x/3x), and this is described in the RM0455 / "Single read sequence" section:

Since the UID is located at the address 0x08FFF800 accessed by the CPU over AHB, it could not be accessed with byte but with half-word or word.
From RM0455:

And in your example you're accessing the UID with bytes:
uint8_t* uid_base = (uint8_t*) 0x08FFF800;
uint8_t i = uid_base[0];
To give better visibility on the answered topics, please click "Best answer" on the reply which solved your issue or answered your question.