This is caused by the way Strava matches segments and determines average speed. When Strava matches you to a segment it's likely there won't be GPS points in your activity that match exactly to the segment start and end points. This means that your segment match can be slightly longer or shorter than the actual segment length.
When we calculate average speed on a segment however, we use the actual segment length, and your measured time on that segment. When we calculate the speed data on an overall activity, we use the length and time of the entire activity.
This is particularly evident on very short segments; the shorter the segment, the larger the percentage of the segment's total time is accounted for by the sampling rate of your GPS device.
Unfortunately, this is simply a limitation of our segment matching process at this time. Unless we do interpolation of your GPS points to time segment efforts, this issue will exist occasionally.
If you're interested, here's more on how to optimize segment creation to ensure this doesn't happen.