PWM Fan over GPIO

Hey Community,

i am new in Home Assistant so please don’t judge me to much over my knowledge.
My HassIO Raspi is installed in a small rack with 2 140mm fans.
Those both fans are 4 pins fans so i would like to control the speed over PWM.

Would it be possible? I found few topics about PWM but none of them was helpful or had no reply to the topics.

Thank you for the help.