Why does my Arduino freezes when i turn a servo
You said that you were using 4x 1.5v batteries. That would make a total of 6 volts. The current that those batteries can supply is also little. 

The Recommended Input Range is 7-12 volts. And the Limit is 6-20 volts.

You were supplying it with 6 Volts which is at the very limit of the Input Voltage Range. When the motor runs, the Voltage might have dropped and made the arduino freeze.

The fix is to supply the arduino with another source such as a benchtop supply that can supply more than 8 volts.