change attributes of player spigot code example
Example: change attributes of player spigot
import org.bukkit.entity.Player;
import org.bukkit.attribute.Attribute;
Player player;
player.getAttribute(Attribute.GENERIC_MAX_HEALTH).setBaseValue(aDouble);