From what I understand, the fundamental group of a topological space $X$ with base point $x\_0$ is the set of all equivalence classes of continuous paths in $X$ that start and end at $x\_0$. Formally speaking:

Let $X$ be a topological space and let $x\_{0}$ be an element of $X$. Consider the set $S$ of continuous loops with base point $x\_{0}$:

$$S=\{f:[0,1]\rightarrow X:f(0)=f(1)=x\_{0}\}.$$ 

The fundamental group of $X$ with base point $x\_{0}$, denoted $\pi\_{1}(X,x\_{0})$, is $S$ modulo homotopy $h$ $(S\bmod h)$, or simply $S/h$. I'm not going to write out the group operation here, because it doesn't relate to my question.

I'm wondering: when the definition says "$S$ modulo homotopy $h$", what does this mean without defining the homotopy $h$? Does it mean *some* homotopy $h$? *Any* homotopy $h$?

I mean we can speak of the set of integers modulo $5$, which is the set of congruence classes of $5$ (i.e., $\{[0]\_{5},[1]\_{5},[2]\_{5},[3]\_{5},[4]\_{5} \}$. So the set of integers modulo $n$ would be $\{[0]\_{n},[1]\_{n},...,[n-1]\_{n}\}$. But without saying what $n$ is, what good is it using that in a definition of something else? For example, $3$ is congruent to $7$ modulo $4$, so $7 \in [3]\_4$. But if $n=8$, then $3$ and $7$ form two different classes. I guess what I'm getting at is: without specifying the homotopy $h$, how can we define what the set of loops modulo $h$ is?

I intuitively understand the fundamental group as being the set of all loops and their deformations that start and end at $x\_0$, but are not homotopic to each other. **Or**, we could say the set of all equivalence classes of loops that start and end at $x\_0$, under the relation homotopy. So we don't include $f\_2$ in the fundamental group if $f\_1$ and $f\_2$ are homotopic. But for one: I'm not sure if either of my intuitive understandings are right, and two: I can't put the intuitive definition together with the formal one. Particularly, this stems from the use of the word "modulo".

If anyone can help me with understanding what the fundamental group is (more generally, a homotopy group), I would appreciate it.