What does “A function on the $n-$gon” mean?

I am reading Dummit and Foote. We have:

For each $n \in \mathbb{Z}^+, n \ge 3$ let $D_{2n}$ be the set of symmetries of a regular $n-$gon, where a symmetry is any rigid motion of the $n-$gon which can be effected by taking a copy of the $n-$gon, moving this copy in any fashion in $3-$space and then placing the copy back on he original $n-$gon so it exactly covers it.

$\vdots$

Then each symmetry $s$ can be described uniquely by the corresponding permutation $\sigma$ of $\{1, 2, 3, ..., n\}$ where if symmetry $s$ puts vertex $i$ in the place where vertex $j$ was originally, then $]sigma$ is the permutation sending $i$ to $j$.

$\vdots$

Now make $D_{2n}$ into a group by defining $st$ for $s, t \in D_{2n}$ to be the symmetry obtained by first applying $t$ then $s$ to the $n-$gon (note that we are viewing symmetries as functions on the $n-$gon, so $st$ is just a function composition)

My question is, what exactly does "we are viewing symmetries as functions on the $n-$gon" mean? E.g. what is the domain and codomain of this function? Is the domain $A = \{$all possible positions of a copy of the $n-$gon such that it overlaps with the original $\}$?

Edit for David Wheeler:

I'm just trying to check my understanding: A symmetry of a square is a bijection $f:A \to A$, where we define $A$ as • The domain (and co-domain) is the $n$-gon itself. If you wish, you can think of it as embedded in $\Bbb R^2$, but that is over-complicating things. – David Wheeler Sep 11 '17 at 0:18
• @DavidWheeler I added a response as an edit to the OP, would you mind taking a look? – Ovi Sep 11 '17 at 3:43
• Given your edit you seem to show that you understand it correctly. – CyclotomicField Sep 11 '17 at 5:20
• Note that you can interpret $D_{2n}$ as the plane isometries that preserve the $n-$ gon, in which case they are effectively functions. – Marc Bogaerts Sep 11 '17 at 18:01