The answer to this question is you are not allowed to use the name "Booking" as a name for a model, a class or something like this in Blazor. I changed the "Booking" class to BookingModel and now it working perfectly fine for me.