Internationella domstolen har slagit fast att Myanmar begick folkmord mot rohingya-minoriteten under 2017 års militära operationer.