Unable to book a column or slot

Hi,

How to book a column which is empty like colored in green and it shouldn’t allowed us to book if its already booked in blue color

Ex: Appointment or booking a slot.
Capture2
Thanks

Please read this: