As concerns about inflation spread, it’s time to gauge how different types of stocks will respond. Smaller companies in niche markets may be better positioned to cope with rising prices—especially in consolidating industries.