Hi @Transidico,
What could be happening is that the flash memory is secured. Could you help me check if the memory is protected?
You can do this using the MCUXpresso Secure Provisioning Tool.

Click the UART button (red). This will open the Connection with Target Processor window.
Test the UART connection by connecting the board through the MCU-Link USB (J13) and using Test connection button (green).
If the flash is secured as shown in the picture, you can try the following:
Open the Command Line Interface (blue) and run the command:
blhost -p COM37,57600 -- flash-erase-all-unsecure
Note: The COM port may vary depending on your setup.
Best Regards,
Pablo