A prominent Hong Kong democracy activist, Joshua Wong, has pleaded guilty to a charge of colluding with foreign interests under a Beijing-imposed national security law.