After hearing the charge the jury may either decide in the jury box or retire for deliberation. If they retire they must be kept together in a room provided for them, or some other convenient place, under the charge of one or more officers, until they agree upon their verdict or are discharged by the court. The officer shall, to the utmost of his ability, keep the jury thus together separate from other persons. He shall not permit any communication to be made to them, nor make any himself unless by the order of the court, except to ask them if they have agreed upon their verdict, and he shall not, before the verdict is rendered, communicate to any person the state of their deliberation or the verdict agreed on. Before any officer takes charge of a jury this section shall be read to him, and he shall be then sworn to conduct himself according to its provisions, to the utmost of his ability.