I changed the relay and thermal sensors on inlet and outlet but nothing changed and the fan kept running about the same length of time.
There is a fan timer somewhere under the dash but I never bothered to change that. If it is running after shutdown it is a good thing and your timer is probably okay. During the time I was fixing this I changed the battery (the parts store checked it and found it was weak so they changed it for free under the warranty).
Your engine it is probably getting too hot if it consistently runs the fan after shutdown.
Check the AC circuit after the car is warmed up, it should turn both fans on when the AC clutch is engaged. Make sure no coolant is leaking anywhere it runs hotter when it is not pressurized properly. If it is transferring coolant between the overflow and the radiator then it is sealed properly.
My thermostat was stuck closed. After changing it still ran the fan after parking although for a shorter time. The thermostat should open at 170 or 180 degrees F the sensor should switch the fan on a little above that.
I wired a switch to my dash to run the smallest fan. I used a 12v switched wire under the dash that was pretty thick and fused it then ran 14 gauge wire through a firewall grommet to the +12 v side of the fan. Now the fan never runs after shutdown.