Solved!
I was using a GPIO controller, but the PWM doesn't work with the default mapping configuration of Recalbox. The solution is to set controllers.gpio.args=map=1 in the recalbox.conf file.
Now the GPIO and the PWM Audio are working simultaneously.
My PWM config is:
dtoverlay=pwm,pin=13,func=4