The structure of 1-(butan-2-yl)-4-tert-butylbenzene is displayed below. What is -yl on this compound and when do I use it?
The "yl" refers to removing a hydrogen atom from a molecule making a univalent group.

Butane is

$\ce{CH3-CH2-CH2-CH3}$

To make butan-2-yl take a hydrogen atom off carbon 2:

$\ce{CH3-CH-CH2-CH3}$

Then butan-2-yl X would be

$\ce{CH3-CH(X)-CH2-CH3}$.