I would create a custom brush for this. Using a small part of the image, adjust the curves to create more contrast, and convert to black and white, erase any extraneous pixels. Define this as a brush. And apply settings similar to those shown below.
Back in your image, select a suitable foreground colour, set the brush size accordingly, and paint with the ...
Your image is not the right representation of the sample you have.
On your reference image, the mortar is lighter than the brick, but in your image it is the inverse.
On section B you have more or less the same mortar color but darker bricks so you notice more the difference.
This probably can be solved using a different texture. Masking the mortar will not ...
In the photograph, the bricks aren't really a different colour. It's just that they're in the shadows, and so that part of the image is slightly less exposed.
So, with that in mind, perhaps try this method:
Convert the image layer to a Smart Object (Right click on the layer name, and choose Convert to Smart Object)
Do Filter > Camera RAW Filter