A group of Anacostia residents led by activist Dick Gregory and Mayor Marion Barry rallied yesterday at the proposed site of a shelter for the homeless in Southeast Washington and then journeyed by motorcade to the White House gate to deliver petitions denouncing the shelter proposal.

Gregory, charging the Reagan administration with indifference to poor people and blacks, told the demonstrators he sympathized with their opposition to the federal government's plan to close a downtown shelter and establish a temporary facility for 600 men in their Anacostia neighborhood. He also warned of the threat posed to the homeless by approaching winter.

"We haven't got much time," he said, standing on a small platform and gesturing toward a stormy gray sky. "Snow is on the way."

Gregory, widely known for fasting on behalf of social causes, told the crowd of about 75 gathered at the proposed shelter site at 1900 Anacostia Dr. SE that he would "start a fast tomorrow to deal with this situation here."

Speeches opposing the shelter by Gregory, Barry, homeless advocate Mitch Snyder, City Council Chairman David A. Clarke and council member Nadine Winter (D-Ward 6) came on the first anniversary of President Reagan's 1984 election eve promise to build a "model physical shelter," a pledge that ended a 51-day hunger strike by Snyder.

Snyder, who heads the Community for Creative Non-Violence, which runs the downtown shelter at 425 Second St. NW, maintains that the federal government backed down on Reagan's promise to build a model shelter and denounced the president yesterday as a "public liar."

Snyder said the administration plans to dump the problem of the homeless east of the Anacostia River, "where they send things that people don't want to see."

Barry reaffirmed his own opposition to the U.S. plan, saying Reagan had made a "social contract."

"He should keep it," Barry said.

The U.S. Department of Health and Human Services contends that the administration was entitled to change plans after Snyder failed to cooperate with the government's original proposal to renovate the Second Street shelter and demanded a more extensive renovation than he was promised.

U.S. District Judge Charles R. Richey, presiding in a suit brought by CCNV against the government, told HHS it could close the Second Street shelter if the agency came up with a plan to relocate the homeless and devise a long-range plan to "elminate homelessness in the nation's capital."

The result was the HHS plan to renovate an old Navy building in Anacostia and give the D.C. Coalition for the Homeless $3.7 million to operate it until April and subsequently open smaller shelters for long-range use.

CCNV appealed Richey's order to the U.S. Court of Appeals for the District, which is reviewing the case. Meanwhile, renovation of the Anacostia shelter is close to completion and the shelter is expected to open soon.

HHS officials declined to comment on the rally or to say when they expect to open the shelter.