It sometimes overshoot on certain steps and I have no Idea is it due to PID controller. I have not tune the PID as I am not familiar.
Overshoot is caused by a gain set too high. Look at your code and reduce the gain until it stops overshooting.
Google around for PID controllers to learn more.