When dealing with mobile apps emulation, one approach is to emulate the environment, use the original binaries (APK in case of Android) and some system hooks to control the app flow.
Another approach is emulating the communication protocol and the various flows between the app and its backend servers. When dealing with social apps like Instagram or TikTok, this requires quite a bit of reverse engineering, emulating device fingerprints and request signatures, but if you manage to get it right, then you have full control of what's going on.
TikTok specifically will detect if the environment is an emulator, it will also check for the presence of Frida hook and other methods typically used by app reversers. IG is looking for TLS fingerprints and for various other behaviors. If you'd like to emulate its communication protocol, then you'll need to dive into their BLOKS protocol, which is a headache...
Having said all that, it depends what you are try to achieve: both apps have different protection levels on different actions and endpoints. So for example, searching or pulling some video info might be possible even if you are running under emulator (or haven't emulated the exact communication flow from code), however adding views/likes or following will require much higher precision and details.