How do you get a section's ID
getSectionByHandle doesn't return an array, but a single SectionModel - so you need to remove the for loop:

{% set enroll = craft.sections.getSectionByHandle('workshopEnrollments') %}

{{ enroll.id }}