Nicaragua said today that its antiaircraft gunners yesterday shot down a rebel airplane and drove away three others near the Costa Rican border.

Fire from guns and rockets brought down a plane about 2 1/2 miles inside Nicaragua in remote jungle while it was on a trip to deliver supplies to antigovernment forces, a Defense Ministry spokesman said. It was the second rebel plane shot down in two days.

Three other planes turned back when they met heavy fire while trying to overfly a military base after dark near the western end of the Nicaraguan-Costa Rican frontier, spokesman Roberto Sanchez said.

In a clandestine radio broadcast from Costa Rica, Eden Pastora, the leader of the Revolutionary Democratic Alliance rebels, claimed reponsibility for the attacks and said the two people killed in the downed plane were pilot Jose Maria Robelo and copilot Henry Casco, United Press International reported.

The government announcement indicated that insurgent forces operating along Nicaragua's southern border possess at least a small air force and that the earlier raids were not isolated incidents.

Despite Nicaraguan protests to the Costa Rican government about the raids, a senior Foreign Ministry official here downplayed his country's differences with its southern neighbor. He said that Costa Rica was doing all it could to restrain the insurgents but that they "have taken the law into their own hands" at the behest of the United States.

The official, who asked to remain anonymous, said that the log book of an attacking Cessna shot down at the airport here Thursday showed that the pilot had made several trips between the United States and Central America. The book will be made public soon, he said.

The air raids have added a new element to the insurgents' fight against the Sandinista government but appear to have had only limited success so far. The planes used are small, propeller-driven ones, and there have been no reports of serious damage caused by their bombs or rockets.

Progovernment radio stations and newspapers have given extensive coverage to the attacks as fresh evidence of what they call U.S. aggression and imperialism.

This morning's newspapers prominently displayed articles on the death of a young customs inspector as the result of burns suffered in the airport attack. Barricada, the official paper of the ruling Sandinista National Liberation Front, called Erwin Garcia Gonzalez "a new martyr of the revolution."

With today's announcement, Nicaragua has reported eight violations of its airspace by insurgent aircraft in two days.

Two Cessnas armed with bombs and perhaps rockets attacked Managua early Thursday morning, and the Defense Ministry identified as T28s the two planes that raided the Pacific port of Corinto at about 5:30 a.m. yesterday.

The Defense Ministry said this afternoon that it did not yet have information on the identity of the plane shot down at 3 p.m. yesterday near the small town of El Castillo de La Concepcion in Rio San Juan province. Sanchez said that recovering the wreckage was difficult because of rough jungle terrain.

The government also could not identify the type of the three planes that were repelled from a military base at Cibalsa in Rivas province just south of La Virgen on the Pan-American Highway.

Sanchez reaffirmed that the two planes that attacked Corinto had flown from Honduras, but this point was the subject of dispute after the Revolutionary Democratic Alliance claimed responsibility for the attack.

The Honduran-based Nicaraguan Democratic Force denied that it had staged the Corinto raid, and the Honduran government denied any involvement. The issue is important because the Honduran-based rebels are known to receive backing from the CIA, whereas the Costa Rica-based group has denied receiving U.S. support.