Well let's take everything in an order...
You make a model for the elementary particles (the standard model) which is a yang mills gauge theory, the renowned SU(3)xSU(2)xU(1). In that case you build an invariant under those gauge groups Lagrangian.
In that model, the (12) gauge bosons, existing in the adjoint representation of those groups, are massless. By elementary particles though, you know that the bosons responsible for the weak interactions are massive. It happens that the Higgs mechanism (introducing a new higgs field) can break the symmetry group:
SU(3)xSU(2)xU(1)→ SU(3)xU'(1)
If that's the breaking take place, some of the gauge bosons acquire mass by interacting with that new field's non trivial vacuum expectation value.
That's a brief explanation of what you stated already.
One could add by hand the masses for the fermions... However the result will not be an invariant Lagrangian under those symmetry groups. For example the mass term of a fermion is given by:
L_{m}= m \bar{\psi_{L}} \psi_{R}
terms in the Lagrangian. L and R means Left and Right components of the Dirac spinor (Weyl Spinors). The Left and Right components though, belong to different representations of SU(2), and so such a mass-term would violate the initial symmetry group (it would explicitly break SU(2) invariance). The left is in the 2dimensional representation while the Right is in the 1dimensional, meaning that the right's SU(2) transformation is like a scalar (doesn't transform) while the left is taking a transformation with exp(iajTj). So what would happen to your mass term under an SU(2)?
L_{m}'= m e^{-iT_{i}a^{i}(x)}\bar{\psi_{L}} \psi_{R} ≠ L_{m}, i=1,2,3
T denotes the generators of SU(2) -can be pauli matrices.
All in all, Higgs mechanism spontaneously breaks the SU(2) symmetry, while adding a mass by hand breaks it explicitly.
You need to make the distinction of left/right handed fermions, because you know that the neutrinos appear with certain helicity (you don't have both left and right handed neutrinos, something which implies also the parity violation of the weak interactions). In that case, you have:
L=(v_{eL},e_{L})^{Τ} (T is transpose because I don't know how to write columns by Latex hehehe excuse me) and R=e_{R} (e means the fermion spinor, take it as just an electron for now).
These could make that distinction since you only have left-neutrinos... the subscripts L, and R means again the components of the Dirac spinor: e_{R/L}=P_{R/L}e_{dirac} with P_{R/L}= \frac{(1\pm \gamma_{5})}{2} the projector operators.
But I wrote in bold above something important. You can make an invariant Lagrangian under the Standard Model gauge group.
After inserting the Higgs field, you also have the freedom to add invariant terms which AFTER higgs acquires a vacuum expectation value, they would lead to mass terms !
Those terms are generally called Yukawa terms in the lagrangian, they are invariant since the Higgs field is also in a doublet of SU(2) so it could kill the transformation caused by the Left component. They mix the Left and Right fermions with the Higgs field, and so when the last gets a vev (let's call it v) then you'll get a form resembling the usual mass term you knew:
G_{e} v \bar{L} R
by comparison with my first formula, you get m=G_{e} v
That's also the mass Bill_K supplied you with, with the only difference that in context we get the vev to be \frac{v}{\sqrt{2}} instead of v I took it here to be for convenient typing.
So in fact we could say that the Higgs field is indirectly responsible for the fermion masses... It just allows you to have consistent extra terms in your initial Lagrangian, which would give you the mass terms result...
For more fermions than just electrons, you just need to put some extra indicies denoting them, the constructions are just identical. For quarks things are a bit different, because you have 1 left doublet and 2 right singlets of SU(2) and you have to mix them somehow with the Higgs field , but the idea is almost the same (it's only the calculations which can be more tedious).
If you feel uneasy with anything I stated feel free to ask again