Catherine was, in regards to foreign policy, a successor to Peter the Great. She wanted to make Russia into one of the great powers of Europe. By most measures of greatness, she succeeded - Russia was to become one of the greatest powers Europe knew in that age. Her reign set the stage for the great rise of Russia in Eurasia. Her role in expanding at the expense of Poland has already been covered, but she also expanded at the expense of another power - the Ottoman Empire.
Her original foreign minister, Nikita Panin, had her ear for a while. He wanted to set up an alliance between northern powers. This would have included Russia, Prussia, Poland, and Sweden. After it became clear that this alliance wasn’t going to happen, he lost her favor and was replaced by Ivan Osterman.
There are a lot of reasons why this “Northern Accord” was never going to work. Russia and Sweden had a lot of historical enmity - most of it stemming from the Great Northern War - and, for the alliance to work, this would need to be dealt with somehow. Destroying the enmity of many generations would’ve been a difficult task, even if an official Northern Accord had been achieved. Prussia and Poland also had a lot of enmity - historically, some of Poland, specifically Royal Prussia, was part of Prussia. Sweden and Prussia also had disputes over Pomerania.
Despite all of this, the idea was somewhat sound and could have been created in part. At different times, Russia did have good relations with both Prussia and Poland. Their good relations with Poland were, indeed, a catalyst for the Partitions of Poland themselves. If Russia had been willing to negotiate a compromise between Poland-Lithuania and Prussia, they could have created an alliance between northern countries. Sweden could have then been dealt with… although that might have created even more enemies of Russia. It definitely would have altered the European balance of power. Sweden could also have been left mostly alone. Poland-Lithuania would likely have been willing to negotiate with Prussia, as it was under severe threat.
However, Catherine wasn’t willing to act as an arbiter, so the idea of an alliance between northern countries went nowhere. However, Russia, Prussia, and Austria would end up in an alliance under the rule of one of her successors (although not her immediate successor), but that was mostly pragmatism. It was a result of the threat of Napoleon - and it did work… eventually.
Instead, Catherine focused on influencing the Polish-Lithuanian Commonwealth. She succeeded at that, getting her candidate for the Polish throne elected via influencing the Polish Sejm. With that done, Poland-Lithuania effectively became her puppet.
This alarmed Prussia and Austria, who feared that Catherine would eventually annex Poland-Lithuania outright. In order to solve that problem, they negotiated with Catherine to partition Poland-Lithuania. The details of this have already been covered, but the gist is this - there were three partitions, and, by their end, Poland-Lithuania had ceased to be an independent state.
It’s kind of confusing as to why Catherine accepted partitioning Poland with Prussia and Austria when she already had indirect influence over all of it. Why would she? There are two likely reasons - either she feared that her influence over Poland would prove ephemeral, or she feared that the disruption to the European balance of power would cause chaos throughout the continent. It is worth noting that Poland did get very close to seizing total independence from foreign influence, which caused the Third Partition.
Why would Catherine protest a change to the European balance of power that benefitted her? That reason was simple - it would make most of Europe her enemy. Prussia and Austria would almost certainly invade her new lands, and she would make Britain (which wanted the continent divided and held in check by a balance of power, so that no country on it could challenge her) her enemy. Even if this didn’t happen, she still risked forcing a series of wars to establish a new balance of power. Catherine likely knew that.
Russia’s annexation of Polish lands also recovered lands lost to Lithuania in previous years. Lithuania had annexed Russian (Kievan) lands back when Russia was still under Mongol control, and most of these lands were returned by the partitions. This was unlikely to be a reason to go through with the Partitions of Poland, though, since nationalism didn’t start being a very influential idea until after Catherine’s reign.