Just an update. I have tried different approaches for the PWM and RPM. Always when I change the PWM, the RPM reading is wrong. Therefore the PWM is messing with the RPM readings, somehow, don't know how to be honest.
Right now I am not sure if it could be solved by different wiring or maybe trying to map the "distorted" RPM to the PWM value