There exists a bunch of population genetics forward and backward (coalescence) simulation platforms. Here is a non-exhaustive list. They all differ and you'll have to go through their manual to see what is more adapted to your needs.
Here is an exhaustive (or almost exhaustive) list of such platforms.
Some are more known than others. Personally, I already saw uses of the following patforms in publication: SimCoal, Nemo, quantiNemo, Splatche, Fish, SFS_Code.
I personally use NEMO. Nemo is well updates, coded in C++ and you are free to bring any modifications you want to the model. But it doesn't mean it is the best model in general and it doesn't mean it is the best model for the detailed thing you want to simulate.
Depending on your level ni programming, it is sometimes faster and easier to just build your own model in C (or C++) if you need performance or otherwise in Python (or Julia which is faster but less people code in Julia than in Python) if you feel more confortable with sllight higher level programming language.
Hope that helps. Good luck!