It's a large, physically long lens (with hood) mounted on a small camera. The built-in flash does not extend high enough for it's spread to clear the hood for shots from 18-50mm or so. I didn't test specifically for the problem. Any shadow of that nature is intrusive and distracting.
The built-in flash on any camera has usage limits. It won't generate shadow when using the 18-55 or 18-105 kit lenses because those lenses are physically long enough to interfere with the spread of the flash. The 18-300 is a physically imposing lens. Don't know about the somewhat smaller/shorter 18-200.
A speedlight mounted in the hot shoe will also throw a shadow that can be seen in image at short focal lengths. If possible get your speedlight off the camera for serious work, and eliminate the problem altogether at any focal length.