You have to learn the pattern. The boss does not have many moves.
Problem here is that in phase 2 it is deliberately confusing and visually cluttered to get you killed. Phase shifting back right into an attack is cheap af and then coming back to have your screen littered with tentacles, mines and the sword attack.
Getting your main weapon to max lvl and 2 archetypes maxed should give you enough damage. Remember that you can upgrade the heart for healing so it has more charges.
Personally I was running gunslinger + medic for that fight. idk if dog can aggro the boss or not + it is prone to dying from all the aoe anyways. Medic shield is great here and gunslinger has nice skills too for dps or spike.
Note: There is an amulet you can get from the nest of a big bird in Yaesha, this amulet decreases relic usage with low hp. It’s great for this battle because you will be very low after a hit so the usage time will be significantly lower.