As the documentation says, this method call returns “a pseudorandom, uniformly distributed int value between 0 (inclusive) and the specified value (exclusive)”. This means that you will get numbers from 0 to 9 in your case. So you’ve done everything correctly by adding one to that number.
Generally speaking, if you need to generate numbers from min to max (including both), you write
random.nextInt(max – min + 1) + min
The standard way to do this is as follows:
Provide:
min Minimum value
max Maximum value
and get in return a Integer between min and max, inclusive.
Random rand = new Random();
// nextInt as provided by Random is exclusive of the top value so you need to add 1
int randomNum = rand.nextInt((max – min) + 1) + min;
See the relevant JavaDoc.
As explained by Aurund, Random objects created within a short time of each other will tend to produce similar output, so it would be a good idea to keep the created Random object as a field, rather than in a method.