Ion beam modification of diamond is important for achieving doping by means of ion implantation, critical dose for graphitization of diamond as well as for understanding the thermal annealing process. Diamond is a unique material, since it is a metastable form of carbon and it may transit into the stable graphite form upon the ion bombardment. A theoretical model for the description of the evolution of Li and B profiles after the ion implantation and annealing process is suggested in this paper. The model consists of three diffusion equations for defect density and doping atoms and also of rate equations for formed new bonds: dangling bond-doping atom. One can take into account the transition from the metastable diamond structure into the stable graphite form in the place where the defect density exceeds a critical volume density of defects Ccrd. For different layers (diamond and graphite) one can use different diffusion coefficients and rate constants for doping atoms. The results of numerical simulation modeling are in qualitative agreement with the experiments and the numerical fitting parameters are in the physically justifiable range.