Attention! We strongly recommend first to learn more about Sites module REST documentation to understand how the module functions (with REST available in Bitrix24 Self-hosted editions). View this documentation as useful source when working with Bitrix24 Self-hosted editions and find out more details about API and only REST is not enough.
Historically, for a long period of time, SItes24 module was created (and used) only in Bitrix24 Cloud editions. It meant that developer's handling of the module was in performed in Cloud. That's why, we strongly recommend to read REST documentation, to understand how module is functioning (with REST available in Bitrix24 Self-hosted as well).