Fix doc comments

Use .copy() when using DesiredCapabilities

Issue 6486
clean up mix if tab and space characters.