The Air Force Titan missile lieutenant under investigation for allegedly passing defense information to the Soviets has charged the chief of the Strategic Air Command with trying to cover up apparent flaws in the immunity agreement that is a key part of the case.

Capt. Francis W. Pedrotty, the attorney for 2nd Lt. Christopher M. Cooke, said in papers filed last week in the U.S. Court of Military Appeals that Cooke should be released from custody and his potential court-martial blocked because Gen. Richard Ellis, the SAC commander, abused his authority in pressing charges.

The court papers quoted an Air Force investigator as saying a superior had heard Ellis was angry because he knew the immunity promise would bar prosecution.

According to the investigator, the superior quoted Ellis as saying that since he was about to retire, "he was going to get Lt. Cooke." Since then, Ellis and his chief legal adviser have kept Pedrotty from taking testimony that would "indicate a cover-up is already taking place," the court papers said.

A SAC spokesman in Omaha declined comment on the charges last night.

Pentagon sources said after Cooke was arrested in late May that codes to nuclear missles had to be changed. At the time, authorities said Cooke, 25, from Richmond, was indentified as having visited the Soviet Embassy here.

Pedrotty and Cooke's civilian attorney, F. Lee Bailey, countered that their client should not be prosecuted in military or criminal courts because he had been promised complete immunity if he cooperated and passed a lie detector test about his contacts with the Soviets.

Justice Department prosecutors are reviewing the case, but have indicated the immunity problem may well bar prosecution on espionage charges.

Pedrotty is taking an unusual step in petitioning the Court of Military Appeals, the final jurisdiction in military cases, before court-martial charges have been formally filed.

His position is the court papers is that the behavior of Ellis and his judge advocate, Brig. Gen. C. Claude Teagarden, has put their subordinates considering the case in an untenable position.

He noted that Air Force investigators contradicted Tegarden at the preliminary hearing. They agreed Cooke had fulfilled the terms of the immunity agreement. "What subordinate is going to call his superior officers liars or in any way question their credibility?" Pedrotty argued in the papers.

The filing gave this chronology of the dispute over the immunity grant:

Two days after his May 5 arrest, Cooke gave an unsigned written statement to Air Force investigators saying he had contacted the Soviets "for purely academic reasons, but did not admit to passing any classified information."

When he entered the case, Pedrotty discussed the immunity agreement with Teagarden and was told Cooke would be allowed to resign without prosecution if he cooperated and passed a polygraph, which he later did.