While accommodations are ideal, there are situations where it simply will not work. A person who is medically unable to drive cannot be accommodated into a role that requires driving, and a person who is unable to use their arms will likely not be suited to a role where heavy lifting is required.
In law these sorts of requirements are known as bona fide occupational requirements, and they are instances where a requirement of a role will mean that certain individuals simply cannot fill the position. These situations are not discriminatory provided they are a good faith requirement of the role.
An employer will not need to accommodate if it would be cost prohibitive for them to do so. Employers are also not required to accommodate if it would potentially harm the safety of others, such as refusing to allow service animals into a sterile environment. Employers have an overall duty to accommodate, but there are situations where they can readily prove that this duty cannot be met.