That's kind of advanced and kind of risky cause let the patients mess your site can result in a terrible thing. But this are somethings you will need to use (i recommend to focus in one at a time) :
*A calendar, either a serverside or clientside one connected to a database
*A form to get data from the patient
*A database to store/change apointments. The calendar doesnt store a thing, it will only display dates. This database will be the memory of the calendar
*A database to store the record (users/password lists) of people that can make/edit appointments
*An action file to get the form data and store it on the database
otherwise, on this link you will find a very usefull example of a very useless table that "looks" like what you want to do,
http://www.scriptingok.com/forum/viewtopic.php?f=5&t=895