This answer is limited to U.S. federal taxation and does not address state income taxation in Massachusetts which is also within the scope of the question.
The relevant statute with respect to a 501(c)(7) organization has the following language:
The following organizations are referred to in subsection (a):
(7)Clubs organized for pleasure, recreation, and other nonprofitable
purposes, substantially all of the activities of which are for such
purposes and no part of the net earnings of which inures to the
benefit of any private shareholder.
Dues or fees are not required to qualify for 501(c)(7) status. But donations are not tax deductible for income tax purposes by the donor. Instead, 26 U.S.C. § 501(c)(7) is an exception from entity level income taxation. Its "profits" are not taxable income to the entity.
The scope of organizations to which contributions are eligible for an income tax charitable deduction are set forth in 26 U.S.C. § 170(c) (set forth below), which excludes 501(c)(7) organizations:
For purposes of this section, the term “charitable contribution” means
a contribution or gift to or for the use of—
(1)A State, a possession of the United States, or any political
subdivision of any of the foregoing, or the United States or the
District of Columbia, but only if the contribution or gift is made for
exclusively public purposes.
(2)A corporation, trust, or community chest, fund, or foundation—
(A)created or organized in the United States or in any possession
thereof, or under the law of the United States, any State, the
District of Columbia, or any possession of the United States;
(B)organized and operated exclusively for religious, charitable,
scientific, literary, or educational purposes, or to foster national
or international amateur sports competition (but only if no part of
its activities involve the provision of athletic facilities or
equipment), or for the prevention of cruelty to children or animals;
(C)no part of the net earnings of which inures to the benefit of any
private shareholder or individual; and
(D)which is not disqualified for tax exemption under section 501(c)(3)
by reason of attempting to influence legislation, and which does not
participate in, or intervene in (including the publishing or
distributing of statements), any political campaign on behalf of (or
in opposition to) any candidate for public office.
A contribution or gift by a corporation to a trust, chest, fund, or
foundation shall be deductible by reason of this paragraph only if it
is to be used within the United States or any of its possessions
exclusively for purposes specified in subparagraph (B). Rules similar
to the rules of section 501(j) shall apply for purposes of this
paragraph.
(3)A post or organization of war veterans, or an auxiliary unit or
society of, or trust or foundation for, any such post or organization—
(A)organized in the United States or any of its possessions, and (B)no
part of the net earnings of which inures to the benefit of any private
shareholder or individual.
(4) In the case of a contribution or gift by an individual, a domestic
fraternal society, order, or association, operating under the lodge
system, but only if such contribution or gift is to be used
exclusively for religious, charitable, scientific, literary, or
educational purposes, or for the prevention of cruelty to children or
animals.
(5) A cemetery company owned and operated exclusively for the benefit
of its members, or any corporation chartered solely for burial
purposes as a cemetery corporation and not permitted by its charter to
engage in any business not necessarily incident to that purpose, if
such company or corporation is not operated for profit and no part of
the net earnings of such company or corporation inures to the benefit
of any private shareholder or individual.
For purposes of this section, the term “charitable contribution” also
means an amount treated under subsection (g) as paid for the use of an
organization described in paragraph (2), (3), or (4).
A separate analysis applies to the question of whether a donation to a 501(c)(7) organization is eligible for the gift and estate tax charitable deductions (26 U.S.C. §§ 2522 and 2055 respectively), or to the charitable deduction for trusts (26 U.S.C. §§ 642 and 664).
Donations to a 501(c)(7) organization are not eligible for the annual exclusion from gift taxation (currently $15,000 per donor per individual donee per year), nor are they eligible for the gift and estate tax charitable deductions (so, in theory, a donation to the 501(c)(7) should be reported on IRS Form 709), but dues and fees are not considered gifts so they don't need to fall within this exemption to avoid gift tax. Form 709 reporting requirements, however, are almost never enforced in practice in this context.
Thus, in a 501(c)(7) organization, a payment of dues, a payment of fees, and a donation, are all identical from a federal income tax perspective. But due and fees are gift tax exempt, while donations are taxable gifts for gift tax purposes (and are not entitled to the estate tax charitable deduction).