PHP only executes its scripts and sends output to the webserver, which decides when and what to send to the webbrowser, which decides when and what to display.
P.S. thorpe suggested using output buffering, not simply "ob_start()". Something like this:
ob_start();
echo "Passwords match.";
sleep(2);
ob_flush();
echo "Passwords match.";
sleep(2);
ob_flush();
echo "Passwords match.";
sleep(2);
ob_flush();
echo "Passwords match.";
sleep(2);
ob_end_flush();
See the manual, esp. the user notes, for flush and ob_flush.