At low speeds, the plane flies at a substantial angle of attack, and so the airflow is not parallel to the plane's axis. Relative to the plane, the airflow is directed several degrees upwards. Now the prop axis is normally parallel to the plane's axis. As the prop rotates, on one side the blades are travelling upwards and on the other side they are travelling downwards. (On most planes, the prop turns clockwise, as seen from behind, so the left side goes up and the right side goes down.)
The upwards angle of the airflow causes the downward (right) side of the prop to have a greater airspeed and angle of attack than the upward (left) side. So the downward (right) side of the prop generates more thrust. Pull harder on the right side of the plane than on the left and the plane will yaw to the left.
This is one of the reasons why most real prop planes need a certain amount of right rudder to keep them straight during takeoff and climbout.
The other factor that requires right rudder on takeoff (in planes with clockwise props) is spiral propwash. The sideways component of the spiral propwash strikes the vertical stabilizer from the left (in conventional single engine configurations), also causing a yaw to the left. In general, the spiral propwash effect is a lot stronger than P-factor.
You also need right aileron to keep the plane straight to counteract the rotational torque from the engine(s).