UK postcodes don't cover polygons. They cover a set of individual delivery points which are not necessarily contiguous.
It is certainly possible, given the co-ordinates for these delivery points, to describe a polygon such that all the co-ordinates are within that polygon. However, such a polygon would not be a unique solution - there would be many polygons that could potentially fit the bill. See, Algorithm to find polygons enclosing pointsAlgorithm to find polygons enclosing points.