This can be complicated and made more so by the use of a third party Lithium-ion battery. Unfortunately the quality of third party Lithium-ion batteries are extremely poor even when purchased from a reputable vendor. Personally I will always choose an official OEM battery whenever possible before I would ever consider a third party battery. The quality is that poor. The best option for a third party Lithium-ion battery is from OWC.
I do know that if a battery is not connected, then it can be difficult to power on an Apple laptop where the power button may need to be held longer or even pressed multiple times before the Apple laptop is able to power on. Also, if the battery is completely discharged, it can prevent the laptop from powering on or even charging. If the new battery has a problem, then maybe it will appear to the Logic Board that no battery is connected or act in a similar matter to a discharged battery. The best you can do is disconnect the battery to see how the laptop behaves. Otherwise you will need to try a known good battery (not very easy with this laptop's design).
Or the laptop may have a bad Logic Board. Or maybe the Logic Board or even the Trackpad was damaged during the battery replacement. I've seen this occur with multiple people posting here on these forums.
As for the issue of not powering completely down, this is more difficult since some app or process may be stuck which prevents macOS from finishing the shutdown. The best ways to troubleshoot this is to try booting into Safe Mode to see if shutting down from Safe Mode has the same issue. Another option is to boot from an external macOS boot drive to see if it will shutdown completely, or you can perform a clean install of macOS to the internal drive and testing the laptop before you install any third party apps or restoring from a backup. Usually most shutdown issues are due to software issues.
The sleep issue may have been due to a swollen battery which may have prevented the closed lid from triggering the sleep sensor. Or if the sleep issue still exists, then maybe the sleep sensor is bad or damaged (or the Logic Board is bad or damaged). Maybe if the laptop thinks the sleep sensor has been triggered during shutdown, maybe it is also causing the shutdown process to stall.