Until judgment is given, the court or justice may remand the prisoner, bail him to appear from day to day, commit him to the sheriff of the county, or place him under such other care and custody as the circumstances of the case require.
Mass. Gen. Laws ch. 248, § 18