Section 5.1 of the main R survival vignette explains the handling of ties in Cox models. The problem with tied event times is illustrated by the denominator in your formula:
$$ \sum_{k\in R(Tj)} e^{x_k*B},$$
which is the summed estimated risks of all those at risk at time $T_j$. With ties, it's not clear which individuals to include in that at-risk group for each of the events at that time. The vignette explains:
The Breslow approximation ... in essence ignores the ties. If two subjects A and B died on day 100, say, the partial likelihood will have separate terms for the two deaths. Subject A will be at risk for the death that happened to B, and B will be at risk for the death that happened to A. In life this is not technically possible of course: whoever died first will not be at risk for the second death.
So the Breslow approximation just solves the standard partial-likelihood score function that you display. It ignores the technical impossibility of all individuals with an event at $T_j$ being in the risk set for all those events.
The Efron approximation instead uses an average of the possible denominators in your formula. The vignette starts with the case of two cases with the same event time, and expands from there:
the Efron approximation is to use the average of the two [possible denominators] as the denominator term. In the software this is easily done by using temporary case weights: if there were $k$ tied events then one of the denominators gives each of those $k$ subjects a weight of 1, then next gives each a weight of $(k − 1)/k$, then next a weight of $(k −2)/k$, etc.
This page describes how to incorporate weights into the partial likelihood for a Cox model. To check your work, I think that the Python lifelines package uses the Efron method as the default for handling ties.