Until judgment is given on the return, the court before whom any party may be brought on such writ may commit the party to the sheriff of the county or place the party in such care or under such custody as the party’s age or circumstances may require.