Your random point is located on a sphere centered on your original point, and whose radius $r$ is the given distance between your two points. So your problem is equivalent to choosing a random point on a sphere. You might want to try and use spherical coordinates to reformulate your problem.
There are several ways to define spherical coordinates, but they always involve a radius $r$ and two angles $\phi$ and $\theta$. In your problem, the radius $r$ is given, and the two angles $\phi$ and $\theta$ must be chosen in a random way.
The simplest way to think of the angles if you're not familiar with spherical coodinates is the way they are used as similar to the coordinates on the surface of the Earth: latitude, and longitude. Latitude is an angle betwen $-90^o$ and $+90^o$, $0$ being the equator, +/- an arbitrary distinction between the two hemispheres (you can choose which is positive), and $\pm90^o$ the latitudes of the poles. A second angle, longitude, between $0$ and $360^o$, will then tell you where you are on the circle of points of same latitude, starting at an arbitrary meridian.
To visualize spherical coordinates, you can also look at a simulation.
Note when investigating spherical coordinates more, you'll most often see angles defined in radian measure rather than degree measure, in which case you should replace $90^o$ and $360^o$ by respectively $\frac\pi2$ and $2\pi$.