As you might know, in some countries it's possible to pay some money (usually a large amount of money) to be exempted from doing military service.
I'd like to know if there is any word or phrase for it in English. Something like "buy military service". Might be funny, but this the literal translation from Farsi to English.
Perhaps you could say they buy themselves out of military service.
Rover
Back when we still had mandatory military service In the US, this was often referred to as "buying your way out of the draft." Folks that avoided conscription via other methods other than outright "buying" their way out - for example, actor George Hamilton reportedly got romantically involved with Lynda Johnson, President Lyndon Johnson's daughter, in order to stay out of Vietnam - were called "draft dodgers."
I don't believe that you could actually buy your way out of the draft, but there were ways of evading it or postponing it, as Ouisch has pointed out.
Gillnetter has commented that you could buy your way out of the draft during the Civil War, but this was through a process known as commutation in the North and substitution in the South. There were differences in practice between the two, but generally speaking, this was a tradition that had long existed in European countries and in the American colonies during the Revolution, whereby you paid someone else to serve for you..