Test Case mapping with Appium function (def)

I am new to Appium and was using calabash for many years so please correct me if my concepts are wrong. I am coding my appium scripts in python. I have mobile test cases that includes multiple steps for my App. My assumption with Appium is that each function is mapped to each test case. My facing issues with following:

  1. After desired capabilities, I’m loggin into app.
  2. The second definition (function) when starts, app relaunches itself.
  3. The next functions assumes that I have progressed some steps, however for every function the app closes and starts over again my test cases fails. It does maintain my login but it starts from the home screen of the app again for each function call.
  4. The main purpose of using function is to generate report that says “Number of test cases: xxxx” I noticed that if I use pytest-html or Allure with appium each function is treated as single test case.

Please, let me know if my understanding of 1 function = 1 test case is incorrect. and How do i maintain my app state between each function calls? I did noRest true but that only prevents appium from reinstalling app. What I need is maintain of step between each function call.