This four to five feet tall shrub is growing in Eastern North America USDA zone 4. I thought it looked like dogwood but the leaves have serrations so it's not that.
It is an elderberry, probably Sambucus nigra. The illustration shows berry clusters where the berries are immature, in the process of turning dark black. One of its advantages is that it is late flowering and will reliably form fruit since the flower clusters appear well after the last frost; also hardwood cuttings root very easily. The berries are good to eat in pies and crumbles (although quite seedy) and even to make wine, but watch out the rest of the plant including stems, leaves, bark, roots are all quite poisonous to people and animals. The birds like the berries, and deer will strip the early foliage from the shrubs but are careful not to eat bark and twigs so while it might appear to be a deer-proof shrub it is not so.
Not to be confused with the native red elderberry which is not good eating except for wildlife. The flower clusters of black elder are flat topped, the red forms a sort of 3-D pyramid or cone shape.