There is a beautiful app called [Button Mapper]( https://play.google.com/store/apps/details?id=flar2.homebutton&hl=en_IN ) . It does exactly what it says, you can remap your remote buttons to do so many things, it has assissstant trigger, and also you can switch between apps with one click!
But can you close apps without going to settings apps force stop? My sony used to have this in android 7.0 and for some reason they removed it