If your goal is to upgrade using miles, the first thing you need to make sure you do is that you purchase a ticket that is upgradeable. This either means purchasing a flight that is operated by United (or if you buy a Lufthansa ticket, it needs to be a specific fare class. But those are generally expensive).
For upgrade costs with miles on a United operated flight, those are fixed depending on the fare class of the Economy ticket that you purchased. The mile cost and copay can both be found here:
Upgrade awards | United Airlines
Now, whether or not you can actually get upgraded if another story. If there are confirmable upgrades at the time of booking, then congratulations, you are guaranteed an upgrade. Otherwise, you will be put on the upgrade waitlist. The likelihood of your upgrade clearing depends on how many seats are available close to departure and how many people have higher priority than you. Flying on a day with lower business demand can improve your odds. Upgrading a premium economy ticket will significantly improve your odds.
That said, generally, trying to book outright with points is "cheaper" (depending on how you value your points). Though you currently do not have enough points on hand to do that, and you generally need some degree of flexibility as there might not be 2 award seats for your desired travel dates. An alternative option is to book a Lufthansa economy ticket directly from Lufthansa and then bid to upgrade to business. But that is also not a guaranteed upgrade.