I'm playing a Hexblade warlock with the War Caster feat.
While holding my staff (an arcane focus) and a shield, can I cast spells without penalty? What if the spell has a consumable component?
There is no reason that it should not work.
A character can use a component pouch or a spellcasting focus in place of the components specified for a spell. But if a cost is indicated for a component, a character must have that specific component before he or she can cast the spell.
PHB pg 203
If your staff is your focus and you don't have the components then you have to hold it. The only issue I would see is that if the spell requires consumable items then you must provide them regardless of if you have a focus.
If a spell states that a material component is consumed by the spell, the caster must provide this component for each casting of the spell.
It is assumed as part of the spell you are reaching into a pocket and finding the components here:
A spellcaster must have a hand free to access these components, but it can be the same hand that he or she uses to perform somatic components.
So I see no reason why needing consumable materials would be an issue, a person could just rest their staff against their shoulder, reach in their pocket, and continue casting the spell.
From the Sage Advice Compendium:
What’s the amount of interaction needed to use a spellcasting focus? Does it have to be included in the somatic component?
If a spell has a material component, you need to handle that component when you cast the spell (PH, 203). The same rule applies if you’re using a spellcasting focus as the material component.
If a spell has a somatic component, you can use the hand that performs the somatic component to also handle the material component. For example, a wizard who uses an orb as a spellcasting focus could hold a quarterstaff in one hand and the orb in the other, and he could cast lightning bolt by using the orb as the spell’s material component and the orb hand to perform the spell’s somatic component.
Another example: a cleric’s holy symbol is emblazoned on her shield. She likes to wade into melee combat with a mace in one hand and a shield in the other. She uses the holy symbol as her spellcasting focus, so she needs to have the shield in hand when she casts a cleric spell that has a material component. If the spell, such as aid, also has a somatic component, she can perform that component with the shield hand and keep holding the mace in the other.
If the same cleric casts cure wounds, she needs to put the mace or the shield away, because that spell doesn’t have a material component but does have a somatic component. She’s going to need a free hand to make the spell’s gestures. If she had the War Caster feat, she could ignore this restriction.