President Bush, claiming some credit for himself, yesterday hailed the "exceptional qualities of leadership" of Soviet President Mikhail Gorbachev and West German Chancellor Helmut Kohl that produced Monday's agreement that a reunified Germany can join NATO.

Bush revealed that he called both leaders early yesterday morning and said he and Gorbachev commiserated over the recent Soviet party Congress that saw the Soviet leader under attack from both left and right. Bush, who is under increased partisan attack on domestic issues and criticism from conservatives in his own party, said he had "commended the politician" in Gorbachev for his handling of the party Congress.

Illustrating the relationship the two superpower leaders have established, Bush ruefully noted, "You talk about a guy getting hit from all sides. I mean, I felt just totally relaxed about what's happenning in this country."

During an interview with magazine publishers yesterday, Bush offered a lengthy outline of the U.S. role in reaching the agreement on Germany's status in NATO.

The president called the Soviet-German agreement "very, very significant and very important" and said it would make a major contribution to stability and peace in Europe. Under the agreement, Moscow would have up to four years to withdraw its 350,000 troops from what is now East Germany and Bonn accepted reductions in the new German army to bring it down to a ceiling of 370,000 soldiers.

Bush, who has always had difficulty publicly touting his successes, was uncharacteristically self-congratulatory yesterday. Some officials suggested that with the increasing conflict over his domestic policies, his foreign policy successes should be emphasized.

The president opened a meeting with GOP congressional leaders by revealing the telephone conversations with Gorbachev and Kohl and acclaiming the Soviet-German agreement. Several of the Republicans emerged from the session praising Bush's foreign policy leadership.

In his statement, the president said it was vital "to put together a solid Western position" on keeping Germany in the NATO alliance despite the Soviet opposition to having its former ally, East Germany, become part of an alliance of longtime opponents.

Having worked to maintain the Western position, Bush said it was then vital for him to convince Gorbachev that NATO was restructuring its military role to meet the changes in Europe. That effort began, Bush said, in talks he had with the Soviet leader during their summit meeting in Washington and continued during the NATO summit in London.

"We had to show him that the NATO alliance was not his enemy, but was a force for stability that could indeed adapt, could change . . . and that's why the recently concluded NATO summit was so important," he said.

Bush, exuding pride in his role at the NATO summit, said the United States had "sent a paper around prior to the NATO meeting and . . . it became the basis for this agreement" that the alliance produced last week calling for wide-ranging changes in the alliance's military and political strategies.

The president quoted Gorbachev as saying that NATO was a "very important impulse" in moving him toward Monday's agreement, and added, "I take such pride in the way Europe is moving into this new era of freedom."

White House officials said Bush's conversation with Gorbachev lasted about 45 minutes and included a presidential rundown on the NATO meeting and the Houston economic summit. White House press secretary Marlin Fitzwater said, "As the architect of the NATO declaration, he wanted to give President Gorbachev personal assurances of NATO's commitment to establish a new relationship with the Soviet Union."

Officials said that Bush reiterated the administration's opposition to immediate economic aid to the Soviets despite the support for such aid by the Germans and others.