It won’t matter if they don’t match. Set up your sag and make sure you don’t just put in what pressure the manufacturer says is correct for your weight, actually measure it, 25-30% is the usual ballpark.
Then it depends what adjustments you have on your shock, I like to buy forks with at least low speed compression adjustment, pretty much everything has rebound adjustment. Adjust your low speed compression to dial out brake dive, set up your rebound so everything feels balanced.
That’s enough for most people. If you want to adjust things more you can add tokens into your fork and shock to adjust how the fork & shock deal with big drops/jump where they go deep into the shock.
You can go back to adjusting the pressure after all of this, some people like the fork to sag less if you’re riding a lot of steep terrain, some people like a lot of sag which can help the bike ‘stick’ to the trail more, I like a firmer ride as I feel it makes it easier to pump and jump when the bike gives you a lot of feedback, but things can get hairy in fast rocky terrain! Different bikes work better/worse in different sag ranges too, so it completely depends on the bike, rider & shocks. Experiment 😀