End caps are often used to transition from vinyl flooring to a sliding glass door or another vertical surface where you wouldn't put a base board (ex. floor to ceiling window).
Install your flooring up to the vertical surface, leaving a 1/2 - 3/4" gap to accommodate the end cap. Sand the base of the end cap (only the portion that will be touching the sub floor). Lay down a strip of glue and put the end cap in place, pushing it snug against the vertical surface with the other end covering the edge of the vinyl plank.