Joey Wendle went 2-for-4 with a double and a run scored, and Cooper crossed the plate twice in Miami's fourth straight victory.
Starter Braxton Garrett (4-2) allowed just one run -- a Rafael Devers solo homer in the fourth -- on three hits across five innings.
A.J. Puk induced a game-ending double play to earn his 12th save after the Red Sox scored a ninth-inning run
Rob Refsnyder, Jarren Duran and Devers all had multiple hits for Boston. Devers scored both runs.
The game turned Miami's way after a one-hour, 13-minute rain delay that interrupted the top of the sixth.
After Red Sox reliever Nick Pivetta (4-5) retired 10 of the first 11 Marlins he faced, Jorge Soler and Bryan De La Cruz drew back-to-back walks immediately before the delay. When the game resumed, Josh Winckowski struck out Chisholm before Cooper walked to load the bases
A wild pitch scored Soler with the go-ahead run, and Jean Segura drove in two more on a two-run single that chopped over the mound and off Red Sox shortstop David Hamilton's glove
Chisholm ripped a one-out homer to deep center in the eighth; and Luis Arraez added an RBI grounder to score Wendle following a leadoff double in the ninth to pad Miami's lead.
Devers and Adam Duvall hit back-to-back one-out singles in the Boston ninth, and Duran knocked a run-scoring single up the middle.
Red Sox opener Kaleb Ort worked around De La Cruz's two-out single in a scoreless first inning, then the Marlins drew first blood as Cooper led off the following frame by golfing a solo home run just over the top of the Green Monster
Ort made way for Pivetta after allowing two hits and the solo homer over his two innings.
Garrett allowed just two hits through the first three innings, then Devers launched a game-tying solo shot into the right-field bullpen with two outs in Boston's half of the fourth.
Pivetta started his 3 1/3-inning relief outing with back-to-back 1-2-3 frames, striking out the side in the fourth.
--Field Level Media