Malaysian police say more than 1,000 migrants from Myanmar and Bangladesh have been "illegally" trying to enter the country at the popular resort island of Langkawi.

The 1,018 migrants, many thought to be members of Myanmar's long-persecuted Rohingya Muslim community, landed on Langkawi late on Sunday night.

Malaysia detains hundreds of migrants

"The first capture by the police was made when a boat with the illegal immigrants was stranded at the beach in Langkawi, [and] the second capture was at Tanjung Biawak, Kuala Temonyong," said Mohd Yusof Abdullah, commander of the Langkawi marine police.

"All the illegal immigrants that have been arrested will be sent to detention centres," he added in a statement.

Police told the AP news agency that officers received a tip-off from a local fisherman that the boats were coming ashore.

Al Jazeera's Karishma Vyas, reporting from Kuala Lumpur, said that the migrants were found in "very poor condition," suffering from severe thirst and hunger.

The migrants were found a day after boats carrying about 500 members of Myanmar's long-persecuted Rohingya community washed ashore in western Indonesia.

The men, women and children arrived on two separate boats, one carrying around 430 people and the other 70, said Steve Hamilton, deputy chief of mission at the International Organisation for Migration in Jakarta, Indonesia's capital.

Last week, the UN's refugee agency said in a statement that an estimated 25,000 Rohingyas and Bangladeshis boarded people smugglers' boats in the first three months of 2015, twice as many in the same months of 2014.

Outcast: Adrift with Burma's Rohingya

"Based on survivor accounts, we estimate that 300 people died at sea in the first quarter of 2015 as a result of starvation, dehydration and abuse by boat crews," the statement said.

In the past weeks dozens of corpses, believed to be of Rohingya, were found in Thai jungles bordering Malaysia.

Rohingya Muslims have for decades suffered from state-sanctioned discrimination in Myanmar.

Attacks on the religious minority by Buddhist mobs in the last three years have sparked one of the biggest exoduses of boat people since the Vietnam War, sending 100,000 people fleeing, according to Chris Lewa, director of the Arakan Project, which has monitored the movements of Rohingya for more than a decade.