Did you try to inject the AppShell by the example code in the official document? In addition, did you try to get the AppShell by
IPlatformApplication.Current.Services.GetService()
?