Your work is correct. To find the volume of a figure between two surfaces, $z=f(x,y)$ and $z=g(x,y)$ where $f>g$, you need to compute the double integral
$$\iint_R f(x,y)-g(x,y) \ dy\ dx$$
The integrand is essentially the height of the volume in the $z$ direction at every point. Your height is $f - g = xy - 0 = xy$.
To choose your bounds for $R$, think of the "shadow" underneath the surfaces. Or, in your case, sketch the triangle formed with $y=x$, $y=0$, and $x=1$.
The bounds you selected match this region. $y$ ranges from $0$ until it hits line $y=x$. Imagine this as creating little vertical strips moving up the x-axis and hitting $y=x$. Then $x$ goes from $0$ to $1$. Here you're adding up all those little vertical strips to have formed your triangle $R$. But all this time, you were computing the height at each point! Hence you have a volume.