The diameter of uniform spanning trees in high dimensions