I'm doing Exercise 9(b) in textbook Algebra by Saunders MacLane and Garrett Birkhoff. Could you please verify if it is fine or contains logical mistakes?
If $G$ acts transitively on a set $X$, then the subgroup $F$ fixing a point $x_{0} \in X$ also acts on $X$. Show that there is a bijection from the set of all double cosets $F g F$ to the set of orbits of $X$ under $F$.
My attempt:
Consider a map $FgF \mapsto F(gx_0)$.
First, we prove it's well-defined. Let $g,h \in G$. Then $FgF = FhF \iff gh^{-1}\in F$. Because $F$ is the subgroup fixing $x_0$, we have $gx_0 = h x_0 \iff gh^{-1} \in F$. Hence $FgF = FhF \iff gx_0 = h x_0 \implies F(gx_0) = F(hx_0)$.
Because $G$ acts transitively on $X$, every $x \in X$ can be written as $g x_0$ for some $g \in G$. Hence the map is surjective.
Second, we prove it's injective. Assume $F(gx_0) = F(hx_0)$, which is equivalent to $gx_0$ and $hx_0$ are in the same orbit. This is in turn equivalent to $\exists g' \in F:g' (gx_0) = hx_0$. This implies $(g'g)h^{-1} \in F$. Because $g' \in F$, we have $gh^{-1} \in F$. This implies $FgF = FhF$.
Update: @Anirban Bose pointed out in a comment that the well-definedness part is incorrect. Here is my fix:
Let $g,h \in G$. Then $FgF=FhF\iff g=f_1hf_2$ for some $f_1,f_2 \in F$. It follows from $f_2 \in F$ that $gx_0 = f_1hf_2x_0 = f_1 (h x_0)$. It follows from $f_1 \in F$ that $gx_0$ and $hx_0$ are equivalent under $F$. As a result, $F(gx_0) = F(hx_0)$.

Here is @Anirban Bose's comment that answers my question. I post it here to remove this question from unanswered list. All credits are given to @Anirban Bose.