Excess Vitamin D doesn't do anything (within reason), but the immune system doesn't work properly when you're vitamin D deficient, and this is something we can measure. Humans haven't evolved for an entirely indoor lifestyle, and we need daily direct sunlight in order to function properly.