Although you asked an outdoors question, I'm going to give you a physics answer that might shed some light (with an outdoors note at the end.) When you string an ideal rope (with zero stretch) horizontally between two ideal vertical trees (with zero give), and then hang an object from the center, the horizontal force pulling on the two trees is... infinitely large.
Of course, in reality it drops off immediately, as the rope stretches and the trees bend. At a sag of 1 degree from horizontal, the force on each tree will be 57 times the mass of the hanging weight. At 5 degrees of sag, it's about 11 times. (And even if your knots are perfect, it takes less than half a percent of rope stretch to get you 5 degrees of sag.)
Why the physics lesson? Just to point out that knots in this setup are taking a LOT more force than most people expect. It's unrealistic to want the rope to hang flat and level. The more sag you're prepared to allow, the easier this problem is. Tying the ends up higher might be easier than tying them tightly enough for your needs.
What about an actual answer to your question? The most basic knot for tensioning a rope in a setup like this is the tautline hitch: https://en.wikipedia.org/wiki/Taut-line_hitch . When tied properly, you can slide it along the rope AFTER tying it to increase the tension, and then it will stay in place. That won't get you the incredible amounts of tension you'll need to hang heavy objects with minimal sagging, but it will probably work for something like a clothesline.
If you need more tension than that, there's a cute trick called a "trucker's hitch": https://en.wikipedia.org/wiki/Trucker%27s_hitch . There are a number of variants, but the basic idea is to tie a loop in the rope, then run the end around the tree and through the loop. This acts like a pulley system, to give you mechanical advantage in pulling the rope tight before tying it off.
A final note of caution: Be careful of the health of the tree when doing this, especially the trucker's hitch or other approaches that create a huge amount of tension. Make sure the trees are solid enough to hold the amounts of force you're applying to them. And while this is ok for temporary usage, don't leave permanent supports tied directly around a tree for a long period of time (like years) -- as the tree grows this can damage or even kill the tree.