When rewriting equations it's important to make the the same operation on both sides to ensure that the equality still holds. So, if one side is divided by a number, the other side must be divided by the same number. In the equation 3x=12 both sides is divided by 3 to solve for x.
33x=312⇔x=4
Remember that division by zero is undefined, so, for example, by dividing both sides by x it is assumed that x cannot be zero.