[1.6.x] Updated advice on six.moves.range/xrange; refs #23812.

Backport of bc88ec550afd5ce972b8c902572c6447d89c0cc9 from master