Let $M$ be a closed orientable $n$-manifold containing the compact set $X$. Given an $n-q-1$-cocyle on $X$ (I am choosing this degree just to match with the notation of the Wikipedia article to which you linked), we extend it to some small open neighbourhood $U$ of $X$. By Lefschetz--Poincare duality on the open manifold $U$, we can convert this $n-q-1$-cocylce into a Borel--Moore cycle (i.e. a locally-finite cycle made up of infinitely many simplices) on $U$ of degree $q+1$. Throwing away those simplices lying in $U \setminus X$, we obtain a usual (i.e. finitely supported) cycle giving a class in $H_{q+1}(U,U\setminus X) = H_{q+1}(M,M\setminus X)$ (the isomorphism holding via excision). Alexander duality for an arbitrary manifold then states that the map $H^{n-q-1}(X) \to H_{q+1}(M,M \setminus X)$ is an isomorphism. (If $X$ is very pathological, then we should be careful in how define the left-hand side, to be sure that every cochain actually extends to some neighbourhood of $X$.)
Now if $M = S^{n+1}$, then $H^i(S^n)$ is almost always zero, and so we may use the boundary map for the long exact sequence of a pair to identify $H_{q+1}(M,M\setminus X)$ with $H_{q}(M\setminus X)$ modulo worrying about reduced vs. usual homology/cohomology (to deal with the fact that $H^i(S^n)$ is non-zero at the extremal points $i = 0$ or $n$).
So, in short: we take a cocycle on $X$, expand it slightly to a cocyle on $U$, represent this by a Borel--Moore cycle of the appropriate degree, throw away those simplices lying entirely outside $X$, so that it is now a chain with boundary lying outside $X$, and finally take this boundary, which is now a cycle in $S^{n+1} \setminus X$.
(I found these notes of Jesper Moller helpful in understanding the general structure of Alexander duality.)