When there is a variance between the allegations of an indictment or bill of particulars which state the particulars of the offense, and the evidence offered in support thereof, the court may order the indictment or bill of particulars amended in respect to the variance, and then admit the evidence.