It's perfectly possible to grow hollyhocks in pots, and they make lovely additions to courtyards and patios. However, the containers need to be deep enough to accommodate their long taproots.
Provide supports and make sure they're somewhere sunny. Remember to water your containers more frequently than plants grown in the ground, as pots tend to dry out quicker. Putting the pots onto pot feet, such as these non-slip UFelice ones from Amazon, will help to prevent the soil from becoming waterlogged.