The US says it is ready to support countries that believe China's territorial claims in the South China Sea are illegal.