If one allows an arbitrary signature, the answer to this question is fairly well-known. Consider the structure $(\lambda,A)_{A\subseteq \lambda}$. Let $(M,R_A)_{A\subseteq \lambda}$ be the common ultrapower by $\mathcal U$ and $\mathcal V$. Note that $A\in \mathcal U$ if and only if $[\text{id}]_U \in R_A$ by the definition of an ultrapower. Fix functions $f,g:\lambda\to \lambda$ such that $[f]_\mathcal V = [\text{id}]_\mathcal U$ and $[g]_\mathcal U = [\text{id}]_\mathcal V$. We have $f_*(\mathcal V) = \mathcal U$: for any $A\subseteq \lambda$,
$A\in \mathcal U$ if and only if $[\text{id}]_\mathcal U\in R_A$ or equivalently
$[f]_\mathcal V\in R_A$, which by definition means $\{\alpha < \lambda : f(\alpha) \in A\}\in \mathcal V$ or $f^{-1}[A]\in \mathcal V$; that is, $A\in f_*(\mathcal V)$.
Similarly $g_*(\mathcal U) = \mathcal V$. It
follows that $(g\circ f)_*(\mathcal V) = \mathcal U$.
A fundamental theorem (discovered independently by Rudin, Keisler, Blass Katetov, Frolík, and maybe others, proof below) states that for
any ultrafilter $\mathcal W$ over $X$ and any $h :X\to X$, if $h_*(\mathcal W) = \mathcal W$
then $[h]_\mathcal W =[\text{id}]_\mathcal W$
Therefore $[g\circ f]_\mathcal V = [\text{id}]_\mathcal V$. Hence there is a set $A\in \mathcal V$ such that $g\circ f\restriction A$ is the identity. In other words, $f$ is one-to-one on a set in $\mathcal V$. It is then not hard to modify $f$ on a null set to make it a permutation.
Proof that $h_*(\mathcal W) = \mathcal W$ implies $[h]_\mathcal W= [\text{id}]_\mathcal W$: Assume not, and so without loss of generality $h(x) \neq x$ for all $x\in X$. Consider the graph $G$ with vertex set $X$ and edge set $E = \{\{x,y\}\in [X]^2 : h(x) = y\}$. We claim $G$ is $3$-colorable. Any finite connected induced subgraph $H$ of $G$ with $n$ vertices contains at most $n$ edges (as $x\mapsto \{x,f(x)\}$ is a partial surjection), and hence contains at most one cycle. Therefore removing at most one edge of $H$ yields an acyclic and hence 2-colorable graph, and this easily implies $H$ is $3$-colorable. By compactness, $G$ is $3$-colorable. Therefore there is a partition $\{A_0, A_1, A_2\}$ of $X$ such that $G\restriction A_n$ is discrete for $n =0,1,2$. This means that $h^{-1}[A_n]\cap A_n\neq \emptyset$ for $n =0,1,2$. Therefore if $A_n\in \mathcal W$, then $A_n\notin h_*(\mathcal W) =\mathcal W$, contradiction.
The question for countably incomplete ultrafilters and finite signatures is far more interesting and seems to be sensitive to set theoretic hypotheses. The answer seems to be yes assuming Woodin's HOD Conjecture. Details on request.
Details: I can actually answer the finite signature question positively without the HOD Conjecture, although my proof looks like overkill. I need a lemma.
Lemma. Suppose $i,j : V_\alpha\to N$ are elementary embeddings that are continuous at regular cardinals $\delta_0 < \delta_1 < \alpha$, and suppose there is a partition $\vec S$ of $\{\alpha < \delta_1 : \text{cf}(\alpha) = \delta_0\}$ into $\delta_1$ stationary sets such that $i(\vec S) = j(\vec S)$. Then $i\restriction \delta_1 = j\restriction \delta_1$.
Given this, we proceed as follows. Consider the structure $M = (V_\alpha,\in,\delta_0,\delta_1,\vec S,f)$ where $\delta_0 > \lambda$ is regular, $\delta_1 \geq 2^\lambda$ is regular, $\vec S$ is a stationary partition as in the lemma, and $f$ is a surjection from the cardinal $2^\lambda$ onto $P(\lambda)$. The ultrapowers of this structure by $\mathcal U$ and $\mathcal V$ coincide, and so we can identify them. Let's say the ultrapower is $(N,E,d_0,d_1,\vec T,g)$. (The signature has one relation symbol, interpreted as $E$, and four constant symbols.)
Let $i,j:V_\alpha \to N$ be the ultrapower embeddings associated to $\mathcal U$ and $\mathcal V$. These embeddings are continuous at $\delta_0$ and $\delta_1$ since these cardinals are regular and above the underlying set $\lambda$ of $\mathcal U$ and $\mathcal V$. Since $i(\vec S) = \vec T = j(\vec S)$, the hypotheses of the lemma are true, so $i\restriction \delta_1 = j\restriction \delta_1$. In particular, these embeddings agree on the ordinal $2^\lambda$.
Now $i[P(\lambda)] = i(f)[i[2^\lambda]] = g[i[2^\lambda]] = g[j[2^\lambda]] = j[P(\lambda)]$. Inverting the transitive collapse shows $i\restriction P(\lambda) = j\restriction P(\lambda)$. This suffices to run the easy argument from the arbitrary signature case.
Proof of Lemma. Let $d_0 = i(\delta_0)$, $d_1 = i(\delta_1)$, $\vec T = i(\vec S) = \langle T_a : a < d_1\rangle$. We run an argument due to Solovay to show that $j[\delta_1]$ is equal to the set $\{a < d_1 : T_a\text{ meets every $\delta_0$-club in $d_1$}\}$. By symmetry (and since $j(\vec S) = \vec T$), we have the same characterization of $j[\delta_1]$, and this proves $i[\delta_1] = j[\delta_1]$, which easily implies the lemma.
(For the record, a set $C\subseteq d_1$ is $\delta_0$-club if it is cofinal in $d_1$ and any increasing $\delta_0$-sequence of elements of $C$ has a supremum in $N$ and this supremum belongs to $C$. Two(?) examples of $\delta_0$-clubs : $i[\delta_1]$ and $j[\delta_1]$.)
First assume $T_a$ meets every $\delta_0$-club in $d_1$, and we will show $a\in i[\delta_1]$. The point is that $T_a$ meets $i[\delta_1]$. Take $\xi < \lambda$ with $i(\xi)\in T_a$. Note that $\text{cf}(\xi) = \delta_0$, so there is some $\alpha < \lambda$ with $\xi \in S_\alpha$. Hence $\xi \in i(S_\alpha) = T_{i(\alpha)}$. Since $\xi \in T_a\cap T_{i(\alpha)}$ and the $T_b$ are pairwise disjoint, $a = i(\alpha)$.
Conversely let us show that $T_{i(\alpha)}$ (i.e., $i(S_\alpha)$) meets every $\delta_0$-club in $\delta_1$. Towards this fix such a $\delta_0$-club $C$. Then the usual argument shows that $C\cap i[\delta_1]$ is a $\delta_0$-club in $d_1$. This means $i^{-1}[C]$ is a $\delta_0$-club in $\delta_1$ in the usual sense. Therefore there is some $\xi \in S_\alpha\cap i^{-1}[C]$. Now $i(\xi)\in i(S_\alpha)\cap C$, so $i(S_\alpha)$ meets $C$, as desired. This proves the lemma.