Many of the hotels in Morocco make use of the Arabic architecture that the country is most known for. Many hotels and hostels alike are considered "riads," which have a central open courtyard in the center.
The courtyard brings in the light and weather which really adds to the atmosphere. It is very much part of the experience to stay in a riad (traditional Moroccan house) while you travel through Morocco.
Morocco accommodation is varied both in quality and price. You can find many luxury options, particularly in the most popular cities such as Marrakesh or Fez. Alternatively, you can arrive without reservations and find budget options in most locations. Riads are the most famous and popular type of accommodation. It's easy to drop a large amount of money on a room in a riad, but you could also find plenty that are affordable and nice.
If you want more modern accommodation, you can often stay just outside the medina area. You'll lose a lot of the atmosphere and character, but it will be made up for in modern amenities.
Marrakech has a huge selection of accommodation options and you shouldn't have any trouble finding something that suits your needs. Most of the budget options are concentrated in the medina area in and around Djemaa el-Fna Square.