Prime Minister Najib Razak has reminded people intending to hold demonstrations that Malaysia had laws that must be followed despite the right to peaceful assembly.