How to test wkwebview in headless

Hi.
I’m trying to test my app which has webpage on wkwebview.

It can be tested on no-headless mode.
But on headless mode it can’t be tested.

appium produce ‘not found element error’.

Test programming language is php.
Does anyone know what this problem is?

i added information.

our appium version is 1.8.2.

the conducted command is here.

vendor/phpunit/phpunit/phpunit test/basic/ShotworksApp.php app="ios application path" device="iPhone 7" version="11.4" isHeadless="true" --testdox-html test/result/result.html --debug --colors=always