Dear Brewer Brewster,
Why, what an interesting question! The reason seems to be two-fold. At one time in history, English men began to professionally take on traditional female jobs such as baking, weaving, etc. Also, perhaps coinciding with that change, the /-ster/ suffix changed meaning from "woman who does X" to "person who does X"; that is, its meaning widened. But you don't have to take my word for it. From the Oxford English Dictionary's entry on the /-ster/ suffix:
In northern Middle English, however, perh. owing to the frequent adoption by men of trades like weaving, baking, tailoring, etc., the suffix came very early to be used, indiscriminately with -er suffix1, as an agentive ending irrespective of gender; thus in the Cursor Mundi (a1300) demestre (see dempster n.) appears instead of demere (deemer n.), a judge, bemestre instead of bemer a trumpeter. It is probable that -ster was often preferred to -er as more unambiguously referring to the holder of a professional function, as distinguished from the doer of an occasional act. In Scotland, baxter and webster survived as masculines down to the 19th c. The only word of this formation that in Scotland has remained exclusively feminine is sewster n.
...From the 16th c. onwards the older words in -ster, so far as they survived, have been regarded as masculines, and several of them have given rise to feminines in -ess, as backstress, seamstress,songstress, huckstress.
You can see that the /-ster/ suffix today is unisex - we have gamster, punkster, hipster. None of those necessarily denotes male or female. Interestingly, as the quote above points out, it was during the 16th century that /-ster/ completely transitioned to a gender-neutral suffix. Apparently as "baxter" transitioned to its current gender-neutral meaning, a new feminine version of "baker" was formed - backstress. Pretty cool! So it seems that "Baxter" became a name passed through the male line because its meaning widened to be associated with men and women, apparently to the point that it was a family name.