Hello Leptonas,
porting the ST25RU3993 HPEV FW to a different MCU depends if the other MCU is also an STM32 or not. When porting from one STM32 MCU to another less porting effort is needed as the FW project uses the STM32 HAL API which is compatible between STM32 MCUs.
Nevertheless the pinout on different STM32 is not the same on different packages or different MCUs. To port this STM32CubdeMX can be used.
When porting to different MCUs all HW dependent peripheral drivers must be ported. The most important is SPI, but there are also Timers, ISR, GPIOs, ADC, UART, ..
Please have also a look to other discussions here on the forum on this topic.
For example how-to replace the MCU on the HPEV board and which HW modifications are needed.
eg.: https://community.st.com/s/question/0D50X0000CBlGLuSQN/how-to-port-the-st25ru3993-firmware-to-a-stand-alone-mcu-board
BR Nick