Well, if it's the primary key, it's automatically indexed (unique index, in fact).
To index other columns, you an either do it when you create the table [if you use a tool to create the table--such as myphpadmin--it probably has an option to make this easy] or you can use a simple SQL command:
Variations on that:
CREATE INDEX nameOfYourChoice ON tablename(columnname);
UNIQUE says there can only be one of each value in the index.
CREATE UNIQUE INDEX nameOfYourChoice ON tablename(column1,column2,column3);
You can specify multiple columns to make up an index, if you wish.
A reasonable index might be
That is, all email addresses ought to be unique.
CREATE UNIQUE INDEX user_email_idx ON users(email);
If you didn't want to allow more than one appointment per user per day. Or remove the UNIQUE to still have the index but allow multiple appointments per user per day.
CREATE UNIQUE INDEX user_appointment ON appointments(userid, appointmentdate);
There are other variations. Check the MySQL manual for "CREATE INDEX" for more options.