A Marine corporal, one of 50 American hostages at the U.S. Embassy in Tehran, said in a television interview last night that he and about 30 fellow captives are being held together and "haven't been mistreated yet at all."

But the Marine, William Allegos of Pueblo, Colo., said he did not know the whereabouts of the other 20 hostages and expressed concern about their fate.

The interview was filmed inside the occupied embassy for NBC television on condition that one of the student captors also be shown making an unedited speech that called for the extradition of the deposed shah. The captors appeared to have orchestrated the interview to refute Carter administration charges that the hostages have been "abused and threatened."

Nevertheless, the interview raised questions about the mental strain on the hostages, which was alluded to by Gallegos, and about those whose locale is unaccounted for.

There were several inconsistencies between statements Gallegos made about the hostages' conditions of detention and what has been reported previously by the students and witnessed by visitors to the embassy.

In a later interview by NBC, White House spokesman Jody Powell said the Iranian staging of the Gallegos interview "was a cruel and very cynical attempt to divert public attention from international demands" that independent observers be permitted to visit the hostages.

Powell predicted that this effort "will not be successful." He said Gallegos' statements "were made under duress and have no validity." He repeated President Carter's assertions that some of the hostages have been interrogated at gunpoint.

Powell said the comments before and after the interview by an Iranian student spokeswoman were "a challenge to the American people" and asked Americans to write to the Iranian Embassy in Washington and the Iranian mission to the United Nations to comdemn this "blackmail."

The spokeswoman read from a prepared speech that included exaggerations about events during the revolution. Appealing to a nation that she said had reacted against governmental actions such as the Vietnam War and Watergate, she repeatedly said, "Now is the time for another test" and called for the return of ousted shah Mohammad Reza Pahlavi, who is recuperating in the United States following cancer treatment.

Gallegos said that his captors had repeatedly accused him of being a CIA agent, a charge that he denied. He also said that although he and other captives had been so accused, he had not been interrogated. He said he did not know whether the others had been.

After saying "The students here have been really good to us." Gallegos disclosed that he and about 30 other captives were being kept in "little cubicles." He described a room divided up by partitions four or five feet high.

Gallegos said each hostage was loosely bound and had a mattress, toliet articles, books to read and enough to eat, but were not allowed to speak to each other or their captors. The Marine, shown by an Iranian television crew throughout the interview with a large color poster of Ayatollah Ruholla Khomeini in the background, added that "the cleanliness is really great."

He said the hostages were allowed to shower every day. This contradicted the reports of other recent visitors to the embassy, including Rep. George Hansen (R-Idaho), who said after seeing some of the hostages that they badly needed baths and changes of clothes.

The Marine said he was allowed to exercise at least three times a day for 15 minutes at a time.

Asked if he would accept a presidential decision to refuse to hand over the shah and leave the hostages in custody indefinitely, Gallegos said, "Yes, sir.I'd have to, sir."

Later, asked by the NBC interviewers what he would like to see happen, the corporal replied. "We're not ready to hold out here forever. I don't know how much longer we can take this. And especially if the shah's not returned, I imagine it would get a little worse. I don't know."

Gallegos, 21, appearing remarkably composed for being held hostage for 37 days, lost some of his composure when he was asked about the 20 hostages whose whereabouts he did not know.

"Where are some of the senior people at the embassy?" Gallegos was asked. "Have you recognized any of them?"

"Senior people as to who, sir?" he answered, showing signs of nervousness about the subject.

"Some of the political officers who are at the embassy," an interviewer said.

"I was with a couple of political officers . . . before we were up here in some of the houses. I was in one of them and after that we were moved down to this other place, mushroom, and I haven't seen, I've seen the other one and then they were taken away with some other ones. They move in and out."

"It doesn't trouble you?"

"Yes it does trouble me. I'm wondering when I'm going to be taken out of here, where I'm going to be taken and what's gonna happen, you know, but as of right now, I really don't have any fears myself. I know that many other officers might have fears in different ways, but I have no fears from the students right now."

Gallegos never explained the meaning of the term mushroom.

The interview also revealed that the students are misleading the hostages about developments in the United States connected with the embassy occupation.

Gallegos said letters received from the United States were "censored" by the captors, who "black out" portions of the letters.