When would I pay my quarterly taxes if I start being self employed in the middle of the year?

I'm obviously new to going to be self employed, but I'm still confused on how the taxes even work. I made out that I'd have to pay 4 quarterlies a year but if I start in the middle of the year would I only have to pay the ones that come up next or would I have to pay the ones I missed and pay the coming up ones? I also don't understand fully how I calculate how much I'd owe for the taxes and how to fill out a 1040-es Form. If someone could please explain as best as possible I know this might be something easy to know but I'm stumped.