You can directly click pop up elements . there is no need to switch in case of native apps
In case you are trying to interact with native app alert, you do not need to switch to alert.
Just find the element on the alert as you find other elements and perform action.
e.g. to click on OK button of alert
driver.findElement(By.id("android:id/ok_button")).click();This workes