All STM32 MCUs have a built-in bootloader which will allow reflashing. The Boot0 pin is used to toggle between "normal" boot and this bootloader.