Would be also nice to limit the a) file size or b) length
You’d be looking for a script not necessarily a template, though most scripts will include templates.
Just google "youtube clone script" or "video sharing script"
There are literally hundreds of different scripts to choose from.
cheaper than paying someone to make it for you
It is cheaper than having someone pay it for you. Just know though, custom stuff – though with a hefty price tag – usually pulls out more income afterwords since ANYONE can setup a site clone, yet what makes the site different?
Also note, for hosting sites like these you need a dedicated server most of the time, since video conversions take a lot of CPU resources and you will defiantly get your shared hosting account banned.
I see the $ signs increasing already (cost-wise)
The best solution, imo, is to start with the script then pay someone to make modifications. It’ll be much cheaper than them building from the ground up.
Also, you can surely find nulled copies of some of the scripts out there but it probably won’t be the latest version. It’ll at least allow you to decide whether or not you want to buy it.