I rarely use the treadmill but when I do, I do the brisk walk at 6kph and run at 8 to 8.5kph. That is a bit slower slower than when I run outside but I don't feel safe going too fast on the treadmill (and always feel dizzy for a bit when I get off).

That would give you 5k in about 37-38 minutes.

I think you just have to experiment with what suits you. Completing the runs is more important than running fast.