What we always have in a ring (or field) is addition, subtraction, multiplication. Division $a/b$, that is the existence and uniqueness of a solution to $bx-a=0$ is different. Even with a field there is not always a soltution (namly if $b=0$ and $a\ne 0$), or it may not be unique (namely if $a=b=0$), so even in a field we only have division if what we divide by is not $0$.
In a ring, additional obstacles may occur. First of all the non-existence, e.g. in $\mathbb Z$ there is no solution to $3x-2=0$. On the other hand $3x-6=0$ does have a solution - and it is unique. If in a ring $R$ with $1$ the equation $bx-1=0$ has a solution, then for all $a$ the equation $bx-a=0$ has a solution. In such a case, $b$ is called a unit of $R$. For example, the units of $\mathbb Z$ are $1$ and $-1$. If all elements $\ne0$ are units, then in fact $R$ is a field.
Another obstacle is the lack of uniqueness. It may happen that two solution exist, i.e. $x_1\ne x_2$ with $bx_1-a=bx_2-a$. This leads to $b(x_1-x_2) = 0$ and in a general ring we can not conclude from this that $b=0$. In such a case, $b$ is a divisor of zero. For example, in $\mathbb Z/12\mathbb Z$, we have $2\cdot 3 = 2\cdot 9 = 6$, so there is no unique meaning we could assign to $6/2$. ($2$ is a divisor of zero because $2\cdot 6=0$ in this ring).
So in a ring the following cases are possible:
- If $b$ is a zero divisor (including $b=0$ itself), a solution of $bx-a=0$ may exist, but even if it exists, it is not unique. Hence divsion by $b$ is not defined.
- If $b$ is a unit, everything is fine: $bx-a=0$ always has one and only one solution. This solution can be denoted as $\frac ab$
- For other $b$ (i.e. neither a unit nor a divisor of $0$), the existence may depend on $a$, but if a solution exists, it is unique. It does make sense to write $\frac ab$ to denote this solution.