Mass is not a conserved quantity in the sub-molecular particle realm (so, in everyday life it's not conserved, but it almost is, and that's good enough for most household chemists).
Energy is a conserved quantity as is momentum, and that conservation includes the possibility that mass either appears or disappears in the system. For particle reactions (like electron-positron annihilation, or its reverse, pair-production) we use a calculated quantity which is invariant under Lorentz transformations: $$E^2-\left(\vec{p}\cdot\vec{p}\right)c^2,$$
where $E$ is the total energy of the interacting system including mas energies, and $\vec{p}$ is the total momentum of the system.
Let's consider your low-energy system of an electron and positron in a reference frame where the electron is at rest and the positron has kinetic energy $\left(\gamma-1\right)mc^2$ and momentum $\gamma mv$. We shouldn't use Newtonian forms because we are including mass-energy and producing photons. The quantity $\gamma$ is just a shorthand symbolic way of writing the quantity $$\gamma=\left(1-\frac{v^2}{c^2}\right)^{(-1/2)}=\left(1-\beta^2\right)^{(-1/2)},\text{ where }\beta=\frac{v}{c}.$$ We can also write the momentum as $p=\gamma m\beta c.$
Then we have
$$E=2mc^2+\left(\gamma-1\right)mc^2=mc^2\left(\gamma+1\right).$$
For our conserved quantity we get
$$ m^2c^4\left(\gamma^2+2\gamma+1\right)-\left(\gamma^2m^2\beta^2c^2\right)c^2.$$
With some simple algebra one can show that $\gamma^2\beta^2=\gamma^2-1,$
so we can write
$$ m^2c^4\left(\gamma^2+2\gamma+1\right)-m^2c^4\left(\gamma^2-1\right)=2m^2c^4\left(\gamma+1\right). $$
Now, if we consider a system of two photons with energies $E_1$ and $E_2$ and corresponding momenta magnitudes $p_1=E_1/c$ and $p_2=E_2/c$, we can write our invariant quantity, keeping in mind that momenta are vector quantities,
$$\left(E_1+E_2\right)^2-\left(\vec{p}_1+\vec{p}_2\right)\cdot\left(\vec{p}_1+\vec{p}_2\right)c^2$$
$$E_1^2+E_2^2+2E_1E_2-\left(p_1^2c^2+p_2^2c^2+2p_1p_2c^2\cos\theta_{12}\right),$$
where $\theta_{12}$ is the angle between the photon momenta. Because each $pc$ term is a photon energy $E$, the invariant quantity of these two photons (which is also the square of the invariant mass or square of the length of the momentum-energy 4-vector) becomes
$$2E_1E_2\left(1-\cos\theta_{12}\right).$$
Now we can equate these two quantities to see if the system of the positron and electron can produce two photons without leftover individual mass:
$$2E_1E_2\left(1-\cos\theta_{12}\right)=2m^2c^4\left(\gamma+1\right).$$
We could certain chose numbers to make this equation work, so the next thing is to see what the experiment provides. An experiment with a positron emitter such as $^{~22}$Na shows two equal energy photons ($E_1=E_2$) emitted in directly opposite directions ($\cos\theta_{12}=\cos\pi=-1$) with energies equal to the mass-energy of an electron (511 keV):
$$4E_1^2=2m^2c^4(\gamma+1)$$
which tells us that $\gamma=1$, or that positron is also at rest when it interacts with the electron.