I'm working on an adventure game in Python using Pygame. My main problem is how I am going to define the boundaries of the room and make the main character walk aroud without hitting a boundary every time. Sadly, I have never studied algorithms so I have no clue on how to calculate a path. I know this question is quite general and hard to answer but a point in the right direction would be very appreciated. Thanks!
Sadly, I have never studied algorithms so I have no clue on how to calculate a path.

Before you start writing games, you should educate yourself on those. This takes a little more effort at the beginning, but will save you much time later.
Adventure game - walking around inside a room