Development of a Monte Carlo code for the data analysis of the 18F(p,α)15O reaction at astrophysical energies