

David Miranda, the partner of the Guardian journalist who broke stories of mass surveillance by the US National Security Agency, has accused Britain of a "total abuse of power" for interrogating him for almost nine hours at Heathrow under the Terrorism Act.

In his first interview since returning to his home in Rio de Janeiro early on Monday, Miranda said the authorities in the UK had pandered to the US in trying to intimidate him and force him to reveal the passwords to his computer and mobile phone.

"They were threatening me all the time and saying I would be put in jail if I didn't co-operate," said Miranda. "They treated me like I was a criminal or someone about to attack the UK … It was exhausting and frustrating, but I knew I wasn't doing anything wrong."

Miranda – a Brazilian national who lives with Greenwald in Rio – was held for the maximum time permitted under schedule seven of the Terrorism Act 2000 which allows officers to stop, search and question individuals at airports, ports and border areas.

During that time, he said, he was not allowed to call his partner, who is a qualified lawyer in the US, nor was he given an interpreter, despite being promised one because he felt uncomfortable speaking in a second language.

"I was in a different country with different laws, in a room with seven agents coming and going who kept asking me questions. I thought anything could happen. I thought I might be detained for a very long time," he said.

He was on his way back from Berlin, where he was ferrying materials between Greenwald and Laura Poitras, the US film-maker who has also been working on stories related to the NSA files released by US whistle-blower Edward Snowden.

Miranda was seized almost as soon as his British Airways flight touched down on Sunday morning. "There was an announcement on the plane that everyone had to show their passports. The minute I stepped out of the plane they took me away to a small room with four chairs and a machine for taking fingerprints," he recalled.

His carry-on bags were searched and, he says, police confiscated a computer, two pen drives, an external hard drive and several other electronic items, including a games console, as well two newly bought watches and phones that were packaged and boxed in his stowed luggage.

"They got me to tell them the passwords for my computer and mobile phone," Miranda said. "They said I was obliged to answer all their questions and used the words 'prison' and 'station' all the time."

"It is clear why they took me. It's because I'm Glenn's partner. Because I went to Berlin. Because Laura lives there. So they think I have a big connection," he said. "But I don't have a role. I don't look at documents. I don't even know if it was documents that I was carrying. It could have been for the movie that Laura is working on."

Miranda was told he was being detained under the Terrorism Act. He was never accused of being a terrorist or being associated with terrorists, but he was told that if – after nine hours – his interrogators did not think he was being co-operative, then he could be taken to a police station and put in jail.

"This law shouldn't be given to police officers. They use it to get access to documents or people that they cannot get the legal way through courts or judges," said Miranda. "It's a total abuse of power."

He was offered a lawyer and a cup of water, but he refused both because he did not trust the authorities. The questions, he said, were relentless – about Greenwald, Snowden, Poitras and a host of other apparently random subjects.

"They even asked me about the protests in Brazil, why people were unhappy and who I knew in the government," said Miranda.

He got his first drink – from a Coke machine in the corridor – after eight hours and was eventually released almost an hour later. Police records show he had been held from 08.05 to 17.00.

Unable immediately to find a flight for him back to Rio, Miranda says the Heathrow police then escorted him to passport control so he could enter Britain and wait there.

"It was ridiculous," he said. "First they treat me like a terrorist suspect. Then they are ready to release me in the UK."

Although he believes the British authorities were doing the bidding of the US, Miranda says his view of the UK has completely changed as a result of the experience.

"I have friends in the UK and liked to visit, but you can't go to a country where they have laws that allow the abuse of liberty for nothing," he said.

The White House on Monday insisted that it was not involved in the decision to detain Miranda, though a spokesman said US officials had been given a "heads up" by British officials beforehand.

The Brazilian government has expressed grave concern about the "unjustified" detention.

Speaking by phone from the couple's home in the Tijuca forest, Miranda said it felt "awesome" to be back. "It's really good to be here. I felt the weight lift off my shoulders as soon I got back. Brazil feels very secure, very safe," he said. "I knew my country would protect me, and I believe in my husband and knew that he would do anything to help me."