STM32 contain several 32-bit backup registers in the VBAT-powered backup domain. In STM32 families with RTCv1 they form a separate BKP module; in families with RTCv2 these registers are part of the RTC module; in models with RTCv3 they are again separated into the TAMP module.
In all STM32 families, the tamper feature clears the backup registers content in hardware, when the tamper event (a level or edge at a dedicated pin) is enabled and active.
While the tamper event is active, the backup registers are held clear and thus cannot be written. The exact details and actions needed to restore writability of the backup registers after a tamper event differ, and have to be looked up in the respective RM, for each of those three variants.