You're probably familiar with the element i, the square root of -1. We joined i to the real numbers to produce the complex numbers. Well now we're bringing in three separate square roots of -1 that are traditionally called i j and k. These elements commute with R and obey the following rules for multiplication.
ij = k, jk = i, ki = j
ji = -k, kj = -i, ik = -j
As you can see, multiplication is not commutative. For instance, ij = -ji. Well actually multiplication might be commutative if the characteristic of R is 2, whence 1 and -1 are the same. But that's rather unusual.
We need to show the quaternions form a ring. Addition is performed per component, as it was with complex numbers, so addition forms a group, with 0+0i+0j+0k (also known as 0) acting as the identity element. Multiplication is defined by distributing the terms and multiplying them individually, so it naturally obeys the distributive laws. The only tricky part is associativity. Show that (ij)k = i(jk), and so on for all the combinations. Don't forget about duplicates, such as (ii)j = i(ij). Sure enough, all combinations are associative, hence the quaternion extension of R forms a larger ring.
Actually, R could be a noncommutative ring, and the quaternion extension still forms a larger ring. We could talk about the quaternion extension of the quaternion extension of R, and so on. But in practice, we want R to be commutative. We'll see why below.
If a quaternion has the form a+bi+cj+dk, where a b c and d are taken from R, the norm of this element is, by definition, a2+b2+c2+d2. As it turns out, the norm is produced when you multiply a quaternion by its conjugate, similar to complex numbers.
(a+bi+cj+dk) * (a-bi-cj-dk) = a2+b2+c2+d2
Next, let x and y be arbitrary quaternions. Perhaps x is a+bi+cj+dk as above, and y is s+ti+uj+vk. Multiply these together and take the norm. Then show this is the same as the product of the individual norms. (You might want to do this on a computer.) Anyways, it works; the norm of xy is the norm of x times the norm of y. Note that this only works when R is commutative, which is why we wanted R to be a commutative ring.
Norm is a map from the quaternions back into R that preserves multiplication. Also, the norm of 1 is 1, hence norm is a monoid homomorphism. If the quaternions form a division ring, norm is a group homomorphism.
In summary, u is a unit iff |u| is a unit.
The key in the above paragraph is that the norm of x is 0 only when x is 0. Let's assume this, and prove a more general result. If xy = 0 then take norms, and |x|*|y| = 0. The norms are nonzero, and are therefore zero divisors. Conversely, assume |x| is a zero divisor. We know that x is nonzero. Write xyw = 0, where x and y are conjugate and w is in the base ring. As long as yw is nonzero, x is a zero divisor. So let yw = 0. Multiply y by w, which scales the coefficients of y by w. this will be 0 only if all coefficients become 0. But this means xw = 0, and x is a zero divisor after all.
In summary, x is a zero divisor iff |x| is a zero divisor.
Apply this to a subring of the reals, where there are no zero divisors, and x cannot be a zero divisor, hence the quaternion extension is a domain. This is what we proved above.