Homeomorphism confusion

I stumbled upon this excerpt as I was reading Graph Theory by Reinhard Diestel:

A polygon is a subset of $\mathbb{R}^2$ which is the union of finitely many straight line segments and is homeomorphic to the unit circle $S^1$, the set of points in $\mathbb{R}^2$ at distance 1 from the origin.

So based on this, how could any polygon be homeomorphic to $S^1$ even though both sets are of different cardinality?

Pardon me if the question is too basic; I'm totally new to topology and I probably am overlooking a detail.

-
Why do the two sets have different cardinality ? – Amr Dec 5 '12 at 21:20
Why do you think the sets have different cardinality? A polygon is the set of points defined by the union of the sets that are defined by line segments, not the set of line segments. – Jason Polak Dec 5 '12 at 21:20
OK, why are you assuming it? – Chris Eagle Dec 5 '12 at 21:24
In that case, the first thing you should do is find a bijection between a line segment like $[0,1)$ and $S^1$. – Jason Polak Dec 5 '12 at 21:26
I just realized what my mistake was.. Thanks a lot :) – Khaled Nassar Dec 5 '12 at 21:28

The cardinality of $S^1$ is the same as the cardinality of any line segment, which in turn has the same cardinality as any finite union of line segments. Cardinality of a set is different from "length" or "measure". For example, though $[1,2]$ is a proper subset of $[0,3]$, the two sets have the same cardinality.