Why $$\int \frac{1}{2x+1}\mathrm dx\neq \ln |2x+1|$$?

While doing integration by partial fraction. I noticed they wrote that $$\int \frac{1}{2x+1}\mathrm dx=\frac{1}{2} \int \frac{2}{2x+1}=\frac{1}{2}\ln |2x+1|$$

Why $2$ is needed in numerator for this type of integration? There's only single $2$ in denominator.