You are exactly correct in that it doesn't generate random strings, which is why I said you have to seed it with the random number. It just takes the text value of that number and turns it into a more random string.
Uniform random number generation is not cryptographically secure it you are wondering, so do not use it for things like hashing passwords (and even session ids is probably not a good idea). But this is the 'easy mode' answer.
Even your example is not cryptographically secure and could probably be guessed by a good cryptanalysis program.
If you want to put a little work into it, I can give you more options.
If you want to search yourself, the key phrase is "cryptographically secure" for any library that you are looking at.